My Question is:
Germany (population 80 million) has the largest population of the countries in Europe. Austria (population 8.5 million) has 11% of the population of Germany.
Show the name and the population of each country in Europe. Show the population as a percentage of the population of Germany.
WHERE population = (SELECT population
What I am doing wrong? Thanks.
Best How To :
The question was incomplete and was taken from here
This is the answer
FROM world WHERE name='Germany'), 0), '%')
WHERE population IN (SELECT population
I was wondering about sub-query as from OP'S question it wasn't clear (at least to me). The reason is that "world" table (as the name suggest, I have to admit) contains all world country whereas we're interested only into european one. Moreover, the population of Germany has to be retrieved from DB because it's not extacly 80.000.000; if you use that number you receive back 101% as Germany population.