Leecode - 1350. Students With Invalid Departments
Problem
Solution
SELECT Students.id, Students.name
FROM Students
WHERE Students.department_id NOT IN (SELECT id FROM Departments)
SELECT Students.id, Students.name
FROM Students
WHERE Students.department_id NOT IN (SELECT id FROM Departments)