How many different locations does each school have?
CREATE TABLE department (school_code VARCHAR, dept_address VARCHAR)
SELECT COUNT(DISTINCT dept_address), school_code FROM department GROUP BY school_code
### Context: CREATE TABLE department (school_code VARCHAR, dept_address VARCHAR) ### Question: How many different locations does each school have? ### Answer: SELECT COUNT(DISTINCT dept_address), school_code FROM department GROUP BY school_code