标签:
表
create table AA_TEST
(
aaaa NVARCHAR2(20),
bbbb NUMBER,
cccc NVARCHAR2(20)
)
删除分两步:先保存满足要求的
delete from aa_test t where (t.aaaa,t.bbbb) not in (
select t1.aaaa,max(t1.bbbb) from aa_test t1 group by t1.aaaa);
第二步再在第一步基础上删去重复记录
delete from aa_test t where rowid not in(标签:
原文地址:http://my.oschina.net/u/1582930/blog/402473