Say I have a table:
Restaurant locations: RESTAURANT_NO | RESTAURANT_LOCATION ----------------------------------- 1 | City A 1
Use DISTINCT.
DISTINCT
try this:
SELECT DISTINCT t.Restaurant_No FROM Restaurant t WHERE t.Restaurant_No NOT IN (SELECT s.Restaurant_No FROM Restaurant s WHERE s.RESTAURANT_LOCATION = 'City C') ORDER BY t.Restaurant_No