SELECT * FROM TB A WHERE NOT EXISTS(SELECT 1 FROM TB B WHERE B.ID>A.ID) GROUP BY A.ONE_ID,A.OTHER_ID
delete a from table1 a left join (select one_id,other_id, max(modify_time) as modify_time from table1 group by one_id,other_id) b on a.one_id=b.one_id and a.other_id=b.other_id and a.modify_time=b.modify_time where b.one_id is null
(select one_id,other_id, max(modify_time) as modify_time from table1 group by one_id,other_id) b
on a.one_id=b.one_id and a.other_id=b.other_id and a.modify_time=b.modify_time
where b.one_id is null
http://topic.csdn.net/u/20090501/15/7548d251-aec2-4975-a9bf-ca09a5551ba5.html
http://topic.csdn.net/u/20100428/09/BC9E0908-F250-42A6-8765-B50A82FE186A.html
http://topic.csdn.net/u/20100626/09/f35a4763-4b59-49c3-8061-d48fdbc29561.html8、如何给分和结贴?
http://community.csdn.net/Help/HelpCenter.htm#结帖
a.one_id=b.one_id and a.other_id=b.other_id and a.modify_time<b.modify_time