I\'ve got the following two SQL tables (in MySQL):
Phone_book +----+------+--------------+ | id | name | phone_number | +----+------+--------------+ | 1 | J
The code below would be a bit more efficient than the answers presented above when dealing with larger datasets.
SELECT * FROM Call WHERE NOT EXISTS (SELECT 'x' FROM Phone_book where Phone_book.phone_number = Call.phone_number)