在一个数据表中没有设置唯一约束导致添加了重复的数据,要想添加唯一约束,首先要把重复记录删除。sql语句:DELETE FROM &tWHERE ROWID IN (SELECT RIDFROM (SELECT ROWID AS RID, ROW_NUMBER() OVER(PARTITION BY a1,a2...ORDER BY ROWID) RNFROM &t)WHERE RN
Copyright © 2005-2024 51CTO.COM 版权所有 京ICP证060544号