update where in limit
update tb1 a set a.end_date ='2011-05-23' where a.id = ( select h.id from ( select id from tb2 history where history.adsite_id =141 and history.en_id=7 order by history.id desc limit 0,1 ) as h )
update的子条件中不能直接带 limit关键字,可以在外围套一层。