Posted By

samwa on 03/23/11


Tagged

sql duplicates


Versions (?)

Who likes this?

1 person have marked this snippet as a favorite

samwa


Find duplicate rows in a table


 / Published in: SQL
 

URL: http://www.petefreitag.com/item/169.cfm

  1. SELECT email,
  2. COUNT(email) AS NumOccurrences
  3. FROM users
  4. GROUP BY email
  5. HAVING ( COUNT(email) > 1 )

Report this snippet  

You need to login to post a comment.