【正文】
che 2 3 che 2 3 che 3 4 dff 3 4 dff 3 4 dff 4 5 err 5 3 dar 6 1 wee 7 2 zxc20 rows selected.:(1).sqlselect * from cz group by c1,c10,c20 having count(*) 1。 c1 c10 c20 1 2 dsf 2 3 che 3 4 dff(3).sqlselect * from cz a where rowid=(select max(rowid) from cz where c1= and c10= and c20=)。sqldelete cz where rowid not in(select min(rowid) from cz group by c1,c10,c20)。sqldelete from cz a where (select max(rowid) from cz b where = and = and =)。(3).適用于有少量重復(fù)記錄的情況(臨時(shí)表法):sqlcreate table test as select distinct * from cz。 (清空cz表的數(shù)據(jù),但保留cz表的結(jié)構(gòu))sqlinsert into cz select * from test。這種方法稍微麻煩一些,為了使用“excepeion into ”子句,必須首先創(chuàng)建 exceptions 表。對(duì)于win2000系統(tǒng)和 unix 系統(tǒng), oracle 存放該文件的位置稍有不同,在win2000系統(tǒng)下,該腳本文件存放在$oracle_home\ora90\rdbms\admin 目錄下;而對(duì)于 unix 系統(tǒng),該腳本文件存放在$oracle_home/rdbms/admin 目錄下。