sql语句 假设表A, 删除字段A1为1的记录delete from A where A1 = 1 and rownum < (select count(*) from A where A1 = 1); 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 请参考http://www.oradb.net/sql/find0.htm A1 ... A1 ... --------- ---------- 1 ... 1 ... 1 ... ==> 2 ... 2 ... 2 ...楼主是这意思吧??如果是这样的话,只能先查出重复记录,再删除. 假设字段id重复,表名borrowdelete from borrow b where b.rowid!=(select min(c.rowid) from borrow c where c.id=b.id); maohuijian(mao) 强, 在下无知, 佩服佩服 delete from table_name a where a.rowid!=(select min(rowid) from table_name b where b.id=a.id); oracle学习 oracle9i数据库加载失败 插入语句时,提示: 缺少 SELECT 关键字 急~~100分求救(不够可以再加):ORA-00600错误。 怎么查天涯IP地址,查天涯发帖人IP,Q:1224714156,如何查天涯博客IP 自动执行存储过程与手动执行有区别吗?? oracle如何写这样的作业 一个简单的SQL语句问题,解决马上结帖! sql server2000里的数据如何导入到oracle9i里呀 重复资料删除问题, 机死人了 口令问题 和 添加权限问题!!!!!!!!! 导入表语句!
--------- ----------
1 ... 1 ...
1 ... ==> 2 ...
2 ...
2 ...
楼主是这意思吧??
如果是这样的话,只能先查出重复记录,再删除.
delete from borrow b where b.rowid!=(select min(c.rowid) from borrow c where c.id=b.id);