Task: Text to Code
Input (English): Step 1: find the department_name of Departments table.
Step 2: find the staff_id of Staff_Department_Assignments table whose date_assigned_to less than the results of step 1
Output (English): SELECT T1.staff_id FROM Staff_Department_Assignments AS T1 WHERE T1.date_assigned_to < ( SELECT T2.department_name FROM Departments AS T2 )