Both of the following queries work perfectly for me at the moment giving out the same results. Which one of the following two are more preferable for huge databases in the long run? Or say, technically which one of these two is a better approach?
SELECT m.* FROM members AS m
LEFT JOIN swipes AS s ON m.mem_id = s.swp_to AND s.swp_by = :mem
WHERE m.mem_id <> :mem AND s.swp_id IS NULL
SELECT m.* FROM members m
WHERE m.mem_id <> :mem
AND NOT EXISTS (SELECT 1 FROM swipes WHERE swp_by = :mem AND swp_to = m.mem_id)
Keeping in mind the future and the heavy users database which one should I go with?