Re: duplicate delete query

2001-08-31 Thread Gerald Clark
ALTER IGNORE TABLE mytable ADD UNIQUE (email); will both add a unique key ( which will avoide this problem in the future ) and delete the duplicates. Rory O'Connor wrote: > excuse me if this is too newbie...but I need to perform a duplicate > delete on my database using the e-mail address as

Re: duplicate delete query

2001-08-30 Thread Carl Troein
Rory O'Connor writes: > I want to leave one record behind, but delete all other records that > have the same e-mail address. Is there a standard query for this or do > I need to write a script that will do it? Getting a list of the duplicate rows is simple enough, but deleting them requires a

Re: duplicate delete query

2001-08-30 Thread Rory O'Connor
I want to leave one record behind, but delete all other records that have the same e-mail address. Is there a standard query for this or do I need to write a script that will do it? THanks, Rory On Thu, 30 Aug 2001 22:35:48 -0500, "Rory O'Connor" <[EMAIL PROTECTED]> wrote: >Do you want to dele

Re: duplicate delete query

2001-08-30 Thread Chris Johnson
Do you want to delete all records which have duplicates, or do you want to delete all the duplicates but leaving one copy of each duplicated record behind? - Original Message - From: "Rory O'Connor" <[EMAIL PROTECTED]> To: <[EMAIL PROTECTED]> Sent: Thursday, August 30, 2001 4:50 PM Subje