Remove duplicate emails and keep only the first occurrence based on the lowest id.?
Query Explaination:
PARTITION BY email → groups by email.
ORDER BY id → keeps the first (lowest id) for each group.
ROW_NUMBER() assigns 1 to the first email, 2 to the next duplicate, and so on.
We delete rows where rn > 1 (i.e., duplicates).