SQL Subquery Exercises: Display the details of departments managed by Susan
SQL SUBQUERY: Exercise-53 with Solution
Write a query in SQL to display the details of departments managed by Susan.
Sample table : departments
Sample table: employees
SELECT * FROM departments WHERE manager_id IN (SELECT employee_id FROM employees WHERE first_name='Susan');
department_id department_name manager_id location_id 40 Human Resources 203 2400
Have another way to solve this solution? Contribute your code (and comments) through Disqus.
Previous: Write a query in SQL to display all the infromation about those employees who earn second lowest salary of all the employees.
Next: Write a query in SQL to display the department ID, full name (first and last name), salary for those employees who is highest salary drawar in a department.
What is the difficulty level of this exercise?