pg_exercises=# SELECT first_name, last_name
pg_exercises-# FROM employees
pg_exercises-# WHERE (employee_id
pg_exercises(# IN (SELECT manager_id
pg_exercises(# FROM employees));
first_name | last_name
------------+-----------
Alexander | Hunold
Den | Raphaely
Steven | King
Neena | Kochhar
Payam | Kaufling
Shanta | Vollman
Kevin | Mourgos
John | Russell
Karen | Partners
Alberto | Errazuriz
Gerald | Cambrault
Eleni | Zlotkey
Lex | De Haan
Matthew | Weiss
Adam | Fripp
Nancy | Greenberg
Michael | Hartstein
Shelley | Higgins
(18 rows)
Sample table: employees
Output:
need an explanation for this answer? contact us directly to get an explanation for this answer