完全重复?..SELECT DISTINCT * INTO # FROM tb_name;TRUNCATE TABLE tb_name;INSERT tb_name
  SELECT * FROM #;DROP TABLE #;

解决方案 »

  1.   

    或者先
    alter table tb add id int identity(1,1)
    go
    delete a from tb a where exists(select 1 from tb where id<a.id and checksum(REPORTID,REPORTNAME,GROUPID)=checksum(a.REPORTID,a.REPORTNAME,a.GROUPID)
    go
    alter table tb drop column id
    go
      

  2.   

    alter table tb_name
    add ID int identity(1,1)
    go
    delete tb from tb_name tb where exists(select 1 from tb_name where REPORTID=tb.REPORTID and
    REPORTNAME=tb.REPORTNAME and GROUPID=tb.GROUPID and ID>tb.ID)
    go
    alter table tb_name
    drop column ID
      

  3.   

    http://www.cnblogs.com/LazyBee/archive/2008/06/05/1214102.html