selecting rows with no reference

From: Date: Wed, 08 Dec 2004 11:30:34 +0000
Subject: selecting rows with no reference
Groups: php.db 
Request: Send a blank email to php-db+get-37636@lists.php.net to get a copy of this message
Hi there, I know this is a question for the mysql mailing list, but maybe one of you guys also could help out with that. I do have to tables (users, messages). Now there unfortunatelly are some messages where the sender in the user table is missing. I am trying to find all messages which do not have the belonging user anymore. So I tried this: SELECT m.subject, m.status FROM user u, messages m WHERE m.sender_user_id != u.user_id But this returns far to many rows. Has anybody an idea how to do that? Thank you in advance, Merlin

« previous php.db (#37636) next »