日期:2014-05-16 浏览次数:20477 次
表test: id priority 1 1 2 2 update test set priority= (case when id=1 then (select priority from test where id=2) when id=2 then (select priority from test where id=1) end) where id=1 or id=2;