Thank you for your time answering!
I was using SQL in SAS and the codes above worked fine to solve the problem of eliminating duple email address in SAS environment. However, when I tried it here in MySQL, it just does not work, not returning the desired outcome, unique email with lowest Id retained.
I think we need to actually delete the rows with duplicated emails from the table, not only select them out.
I don't know SAS but I'm pretty certain
SELECT doesn't delete anything there, either. That's just not what
SELECT is for.
SELECT you are showing things you want to show which means hiding the other things you don't want to present. But hiding things does NOT mean deleting. We can show the hidden things whenever we use SELECT to them, but we will no long be able to show things after deleting. So not SELECT-ing doesn't mean deleting. Here we need to use
Looks like your connection to LeetCode Discuss was lost, please wait while we try to reconnect.