oracle中重复记录只取其中一条

select * from table1 where rowid=any(select max(rowid) from table1 group by field1)

或者

select * from table1 where rowid in (select max(rowid) from table1 group by field1)

posted @ 2009-06-11 12:25  魔豆  阅读(1975)  评论(0编辑  收藏  举报