Results 1 to 2 of 2

Thread: duplicate rows

  1. #1
    Join Date
    Jul 2003
    The Dark Planet

    Unanswered: duplicate rows

    What is the best way to remove duplicate rows from a table ?

  2. #2
    Join Date
    Sep 2003
    Dallas, Texas

    Re: duplicate rows

    There were a couple of ways that I have tried worked. The first one is to use 'set rowcount 1' then delete the row with count(*) > 1. The second works better for large tables. Insert into TempTable select distinct * from RealTable. Delete all row with count(*) > 1, and then insert the temp table rows back to the real table.

    Hope this helps. Good luck!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts