How many different locations does each school have?
SELECT count(DISTINCT dept_address) ,  school_code FROM department GROUP BY school_code
different locations for each school refers to COUNT(DISTINCT dept_address); grouped by each school refers to GROUP BY school_code;