tommym121
asked on
SQL - How to count duplicate record
I have a table with firstName, lastName and other fields, I will like to count all the rows have the same firstName and lastName.
SELECT firstname, lastname, COUNT(*) FROM person GROUP BY firstname, lastname HAVING COUNT(*) > 1;
Something like this perhaps:
SELECT COUNT(DISTINCT firsname + lastname)
FROM YourTable
SELECT COUNT(DISTINCT firsname + lastname)
FROM YourTable
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
Thanks