CREATE TABLE department (name VARCHAR2, departmentid VARCHAR2)
CREATE TABLE affiliated_with (department VARCHAR2)

List the names of departments where some physicians are primarily affiliated with.
SELECT DISTINCT T2.name FROM affiliated_with AS T1 JOIN department AS T2 ON T1.department = T2.departmentid WHERE PrimaryAffiliation = 1
SELECT DISTINCT "T2"."name" FROM "affiliated_with" "T1" JOIN "department" "T2" ON "T1"."department" = "T2"."departmentid" WHERE "PrimaryAffiliation" = 1