oracle update 前100條

這個沒有好的辦法,就是嵌套層表。大巧若拙,笨方法就是好方法:

update t_order set status='3' where id in (
  select t.id from
  (
    select id from t_order where status='9'  order by create_date desc
  ) t
  where rownum < 500
)
發表評論
所有評論
還沒有人評論,想成為第一個評論的人麼? 請在上方評論欄輸入並且點擊發布.
相關文章