假设表A, 删除字段A1为1的记录
delete from A where A1 = 1 and rownum < (select count(*) from A where A1 = 1);

解决方案 »

  1.   

    请参考http://www.oradb.net/sql/find0.htm
      

  2.   

    A1  ...         A1  ...
      ---------       ----------
        1  ...         1   ...
        1  ...    ==>  2   ...
        2  ...
        2  ...
    楼主是这意思吧??
    如果是这样的话,只能先查出重复记录,再删除.
      

  3.   

    假设字段id重复,表名borrow
    delete from borrow b where b.rowid!=(select min(c.rowid) from borrow c where c.id=b.id);
      

  4.   

    maohuijian(mao) 强, 在下无知, 佩服佩服
      

  5.   

    delete from table_name a where a.rowid!=(select min(rowid) from table_name b where b.id=a.id);