SELECT COUNT(DISTINCT T2.id), COUNT(DISTINCT T3.id), T3.dept_name FROM department AS T1 JOIN student AS T2 ON T1.dept_name = T2.dept_name JOIN instructor AS T3 ON T1.dept_name = T3.dept_name GROUP BY T3.dept_name
Temukan jumlah total siswa dan jumlah total instruktur untuk setiap departemen.
CREATE TABLE department (dept_name VARCHAR); CREATE TABLE student (id VARCHAR, dept_name VARCHAR); CREATE TABLE instructor (dept_name VARCHAR, id VARCHAR)