List:General Discussion« Previous MessageNext Message »
From:Keith Burke [Experience IT] Date:September 6 2002 10:52am
Subject:how to find double
View as plain text  
JF,

	You could try this, if I understand you correctly

	=======
	SELECT count(field_name), field_name
	FROM table_name
	GROUP BY field_name
	HAVING count(field_name) > 1
	=======

	or HAVING count(field_name) = 2 , to find records that are in
there twice and no more than that.





Regards

**************************************************************
*       K   e   i   t   h           B   u   r   k   e        *
**************************************************************
* Experience IT Ltd       * Phone : +353 1 xxx xxxx          *
* Unit G6                 * GSM   : +353 86 xxx xxxx         *
* Riverview Business Park * Email : kburke@stripped     *
* New Nangor Road         * WWW   : http://www.experience.ie *
* Dublin 12               *                                  *
* Ireland                 *                                  *
**************************************************************


-----Original Message-----
From: jf Leoni [mailto:jfleoni@stripped] 
Sent: 06 September 2002 11:28
To: mysql@stripped
Subject: how to find double


hello,

i have a table with 10 500 000 rows on a mysql database

how can i find doubles  ?? i know how to do it using php, but maybe
there 
is a way using only queries?

tks

JF leoni


---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <mysql-thread118928@stripped>
To unsubscribe, e-mail
<mysql-unsubscribe-kburke=experience.ie@stripped>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Thread
how to find doubleKeith Burke [Experience IT]6 Sep