今天用oracle建了一个表之后,写进去无数个重复的记录,不知道如何才能删除呢?问老师,老师只是说了rowid,具体rowid是什么呢?

解决方案 »

  1.   

    truncate table xxx
    删除表中所有的数据
      

  2.   

    delete from table where rowid not in (select max(rowid) from table group by 字段);
      

  3.   

    不是字段啊!数据insert……into插入进去的数据重复啊!我晕死啦……
      

  4.   

    elete from table_name a
    where rowid< (select max(rowid) from table_name
     where column1=a.column1 and column2=a.column2
      and colum3=a.colum3 and ...)