Page 1 of 1

Remove db dublicates

Posted: Fri Oct 03, 2008 6:42 pm
by Arsench2000
Hello world, is there any example to remove from DB dublicated records?

Thank you

Re: Remove db dublicates

Posted: Sat Oct 04, 2008 8:53 pm
by yacahuma
what colum type is the duplicate?(integer,string,char...)??

Re: Remove db dublicates

Posted: Sun Oct 05, 2008 4:18 am
by VladSun
Arsench2000 wrote:Hello world, is there any example to remove from DB dublicated records?

Thank you
You mean "all of the duplicated items" or "all of the duplicated items except one"?

Re: Remove db dublicates

Posted: Mon Oct 13, 2008 9:22 pm
by efortis
Do you want to delete them from the DB? or
just select distinct tuples from the table?

Code: Select all

 
SELECT DISTINCT (field) 
FROM table 
GROUP BY field