How many distinct students have been in detention?
SELECT count(DISTINCT student_id) FROM Students_in_Detention
how many = COUNT(); distinct students = DISTINCT(student_id); been in detention refers to selection from Students_in_Detention table;