Employees Whose Manager Left the Company
Task: Find the IDs of the employees whose salary is strictly less than $30000 and whose manager left the company. When a manager leaves, their information is deleted.
Table: Employees
+-------------+-------------+
| Column Name | Type |
+-------------+-------------+
| employee_id | INT |
| name | varchar(20) |
| manager_id | INT |
| salary | INT |
+-------------+-------------+
Input: Employees table:
+-------------+-----------+------------+--------+
| employee_id | name | manager_id | salary |
+-------------+-----------+------------+--------+
| 3 | Mila | 9 | 60301 |
| 12 | Antonella | null | 31000 |
| 13 | Emery | null | 67084 |
| 1 | Kalel | 11 | 21241 |
| 9 | Mikaela | null | 50937 |
| 11 | Joziah | 6 | 28485 |
+-------------+-----------+------------+--------+
Output:
+-------------+
| employee_id |
+-------------+
| 11 |
+-------------+