Created
April 3, 2016 22:34
-
-
Save bq1990/9d8ca6d321ce54749fb81710e09da7f3 to your computer and use it in GitHub Desktop.
sql select duplicate emails
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
select trim(lower(email)), count(*) | |
from "users" | |
group by trim(lower(email)) | |
HAVING count(*) > 1 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment