Skip to content

Instantly share code, notes, and snippets.

@bungard
Created October 28, 2014 13:45
Show Gist options
  • Save bungard/fe79905e9094cea67c41 to your computer and use it in GitHub Desktop.
Save bungard/fe79905e9094cea67c41 to your computer and use it in GitHub Desktop.
SELECT model
FROM
(SELECT model, price FROM PC)
UNION
(SELECT model, price FROM Laptop)
UNION
(SELECT model, price FROM PC) model_price
WHERE
price >= ALL (SELECT price FROM model_price);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment