Last active
June 17, 2019 10:34
-
-
Save igeligel/d6923cf418f1ea9f3ad158df3749c413 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
SELECT *, | |
CASE | |
WHEN name = ANY(ARRAY['Airbus A333-300', 'Airbus A380-800']) THEN 'airplane' | |
WHEN name = ANY(ARRAY['Volkswagen Golf', 'Porsche Cayenne']) THEN 'car' | |
ELSE null | |
END AS type | |
FROM vehicles; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment