Task: Text to Code
Input (English): SQL: SELECT T1.Name FROM Physician AS T1 JOIN Department AS T2 ON T1.EmployeeID = T2.Head WHERE T2.Name = "Psychiatry" OR T2.Name = "Surgery"
Feedback: Make sure that the Physicians need to affiliated with relevant department department .
Output (English): SELECT T1.name FROM physician AS T1 JOIN affiliated_with AS T2 ON T1.EmployeeID  =  T2.physician JOIN department AS T3 ON T2.department  =  T3.DepartmentID WHERE T3.name  =  'Surgery' OR T3.name  =  'Psychiatry'