mysql update... order by
Some time, we need update a column with unique index. For example: "update tree set lft = lft + 2 where lft > 0". If the lft column is: "1, 2, 3, ..." MySQL will throw an duplication error. To solve the problem, a clause " order by lft DESC" need to be added.
But there is no order_by method in update() function in 0.5x.