CREATE TABLE COUNTRIES (Continent VARCHAR); CREATE TABLE CONTINENTS (ContId VARCHAR, Continent VARCHAR)
How many countries does each continent have? List the continent id, continent name and the number of countries.
SELECT T1.ContId, T1.Continent, COUNT(*) FROM CONTINENTS AS T1 JOIN COUNTRIES AS T2 ON T1.ContId = T2.Continent GROUP BY T1.ContId