Re: finding and removing duplicates rows

From: Hugo Kornelis (hugo_at_pe_NO_rFact.in_SPAM_fo)
Date: 03/17/04


Date: Thu, 18 Mar 2004 00:54:00 +0100

On 17 Mar 2004 05:24:49 -0800, Stephen wrote:

>Thanks for the message, it definately helped solve a lot of issues.
>
>Is there a way to do everything mentioned, but without having a unique
>key for each record?

No. If all columns in two rows are the same, there's no way to tell
them apart. Any where clause will either select both rows or none of
them. If you want to eliminate duplicates, you have to add an IDENTITY
or GUID column, or else you will delete both rows instead of one of
the duplicates.

Best, Hugo

-- 
(Remove _NO_ and _SPAM_ to get my e-mail address)


Relevant Pages

  • Re: Help with Duplicate Query
    ... If everything is same and amount is above 100, ... should these be regarderd as duplicates: ... Best, Hugo ... (Remove _NO_ and _SPAM_ to get my e-mail address) ...
    (microsoft.public.sqlserver.server)
  • Re: Keith Thompsons messages dont come through
    ... <snip: issues with news propagation> ... different servers and aggregate them in a single local store, ... Resolves true duplicates across servers and ... with some spam but not all. ...
    (comp.lang.c)
  • Re: Keith Thompsons messages dont come through
    ... <snip: issues with news propagation> ... different servers and aggregate them in a single local store, ... Resolves true duplicates across servers and ... with some spam but not all. ...
    (comp.lang.c)
  • Re: Is there a query for this?
    ... >Or, for a more flexible approach, load the values you search in a temp ... >table (#TempTab in the below query) and execute: ... >Best, Hugo ... I missed the duplicates in your sample data. ...
    (microsoft.public.sqlserver.programming)
  • Re: Keith Thompsons messages dont come through
    ... duplicates ... The documentation for xnews implies it can do this (not the spam part ...
    (comp.lang.c)