> zv Green wrote:
>> Hello all,
>> 
>> What  I want to do is select all the records from the table but where
>> there
>> are duplicate entries (based on say, the surname and postcode fields)
>> pick a random record and then ignore the rest.
> 
> If you want to pick a random record, you can do ORDER BY RANDOM LIMIT 1
> or so. (warning, untested)

And I think you will want to group by surname and postcode in order to
filter out the duplicates.
-- 
-------------------------------------------------------------
Scott Haneda                                Tel: 415.898.2602
<http://www.newgeo.com>                     Novato, CA U.S.A.



-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to