I have two tables: one contains user logins and the other contains user data. I would like to delete users who may or may not exist in the latter table but definitely exist in the former. How do I account for users who may or may not exist? Please note that it should be in one query....
I have tried:
DELETE houses,houseusers FROM houses INNER JOIN houseusers ON houseusers.username = houses.username WHERE houses.username='user1' OR houseusers.username='user1';