Skip to content

Instantly share code, notes, and snippets.

@mcanaves
Last active February 16, 2017 17:39
Show Gist options
  • Save mcanaves/b99df46c8dd53879bbcb027784795e80 to your computer and use it in GitHub Desktop.
Save mcanaves/b99df46c8dd53879bbcb027784795e80 to your computer and use it in GitHub Desktop.
Search for duplicated records with SQL
SELECT <filter_column1>, ..., <filter_columnN>, count(*)
FROM <table>
GROUP BY <filter_column1>, ..., <filter_columnN>
HAVING count(*) > 1;
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment