I was not aware of that change.  That actually makes the command useful.

Troy

===== Original Message from [EMAIL PROTECTED] at 8/27/02 2:01 pm
>Troy,
>
>Sometime ago the command was changed so that you can delete dups based on
>certain columns which is more useful - and much more dangerous if you are
>not very careful.
>
>The snippet below is pasted from R:Syntax for Del Dup:
>
>
>The following example deletes duplicate rows based on the transid, empid,
>and custid columns in the transmaster table. Only the designated columns
>will be used to determine whether the rows are duplicates.
>
>DELETE DUPLICATES FROM transmaster USING +
>transid, empid, custid
>
>Regards,
>Alastair.
>
>----- Original Message -----
>From: "Troy Sosamon" <[EMAIL PROTECTED]>
>To: <[EMAIL PROTECTED]>
>Sent: Tuesday, August 27, 2002 5:40 PM
>Subject: RE: Delete Duplicates
>
>
>> The delete duplicates only works if the entire row is a duplicate.
>> I have never found the commend of much use.
>> I assume you have a unique row identifier that is different for each
>> duplicated ponum
>>
>> Make a temp table w/ ponum in it, and insert 1 row for each ponum w/
>> duplicated records.
>> insert into temptable (ponum) select ponum from poheader group by ponum
>> having count * > 1
>>
>> Make a second temp table with 2 columns, ponum and rowid, and insert 1 row
>> for every record in poheader where the ponum is in the temptable.
>>
>> Now go manually delete 1 row for each ponum in the second temp table for
>the
>> record you want to keep.
>>
>> Now delete the rows using the second temp table.
>> delete from poheader where rowid in (sel rowid from second_temp)
>>
>> Troy
>
>================================================
>TO SEE MESSAGE POSTING GUIDELINES:
>Send a plain text email to [EMAIL PROTECTED]
>In the message body, put just two words: INTRO rbase-l
>================================================
>TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
>In the message body, put just two words: UNSUBSCRIBE rbase-l
>================================================
>TO SEARCH ARCHIVES:
>http://www.mail-archive.com/rbase-l%40sonetmail.com/

================================================
TO SEE MESSAGE POSTING GUIDELINES:
Send a plain text email to [EMAIL PROTECTED]
In the message body, put just two words: INTRO rbase-l
================================================
TO UNSUBSCRIBE: send a plain text email to [EMAIL PROTECTED]
In the message body, put just two words: UNSUBSCRIBE rbase-l
================================================
TO SEARCH ARCHIVES:
http://www.mail-archive.com/rbase-l%40sonetmail.com/

Reply via email to