What are the names and ids of the different categories, and how many films are in each?
SELECT T2.name ,  T1.category_id ,  count(*) FROM film_category AS T1 JOIN category AS T2 ON T1.category_id  =  T2.category_id GROUP BY T1.category_id
names and ids of the different categories refers to T2.name, T1.category_id; how many films in each category refers to COUNT(*); joining tables film_category and category on category_id refers to JOIN ... ON T1.category_id = T2.category_id; grouping results by category_id for aggregate count refers to GROUP BY T1.category_id;