12 lines
434 B
SQL
12 lines
434 B
SQL
/*Write a query in SQL to display the department name and Id for all departments where they located, that Id is equal to the
|
|
Id for the location where department number 30 is located.
|
|
|
|
*/
|
|
|
|
SELECT department_name, department_id
|
|
FROM departments
|
|
WHERE location_id =
|
|
(
|
|
SELECT location_id
|
|
FROM departments
|
|
WHERE department_id = 30); |