MySQL not in other table

SELECT *
FROM   `a`
WHERE  NOT EXISTS
(SELECT *
FROM   `b`
WHERE  `b`.`id` = `a`.`id`)

Leave a Reply

Your email address will not be published. Required fields are marked *