GitGotGo1 / sem

Repository of GitGotGot Java application using SQL to output reports
Apache License 2.0
0 stars 5 forks source link

The top number of populated cities in a region where the number is provided by the user. #27

Open rosshardie opened 5 years ago

rosshardie commented 5 years ago

As a user I want to be able to see the top number of populated cities in a region where the number is specified by me

Amckenzie93 commented 5 years ago

City Report A city report requires the following columns:

Causeless commented 5 years ago
SELECT
    city.Name,
    country.Name,
    city.District,
    city.Population
FROM city
JOIN country ON country.Code = city.CountryCode
WHERE country.Region LIKE 'Caribbean' -- region taken from user input
ORDER BY city.Population DESC
LIMIT 10; -- number taken from user input