There are tables A and B related by a one-to-many relationship, respectively.
You must select all records A that do not have records associated with them in B.
There are tables A and B related by a one-to-many relationship, respectively.
You must select all records A that do not have records associated with them in B.
JOIN to help you. Probably like this:
SELECT * FROM TableA FULL OUTER JOIN TableB ON TableA.name = TableB.name WHERE TableA.id IS null OR TableB.id IS null id name id name -- ---- -- ---- 2 Monkey null null 4 Spaghetti null null null null 1 Rutabaga
null null 3 Darth Vader
Source: https://ru.stackoverflow.com/questions/199240/
All Articles