[RESOLVED] Finding duplicate values in a DB Table?
I always forget how to do this but I'm trying to write a SQL query that identifies a specific column per row that has duplicate values. In other words, there may be 5 rows where the LastName has the same value. How do I write a query that will return only those rows?
Thanks,
Re: Finding duplicate values in a DB Table?
Something like this:
Code:
Select LastName,Count(*) From tablename Group BY LastName Having Count(*) > 1
Re: Finding duplicate values in a DB Table?
Thanks Gary...that's what I was lookin' for!