SQLZOO练习题(1)
sqlzoo上较难的一些sql查询练习题及其解题思路。
题目:
Put the continents right…
- Oceania becomes Australasia
- Countries in Eurasia and Turkey go to Europe/Asia
- Caribbean islands starting with ‘B’ go to North America, other Caribbean islands go to South America
Show the name, the original continent and the new continent of all countries.
答案:
select name, continent, case
when continent='oceania' then 'Au