Worked solution from the Databases Paper 2 Algorithms, Programming and Logic booklet, Part 2 of 2.
Pick one field for each type:
| Data type | Field |
|---|---|
| Boolean | Subway |
| integer | Population (or Founded, Identification) |
| real | AverageIncome |
| text | Name (or Country, Continent, Identification) |
All four correct [2]
Note: two or three correct scores [1].
SELECT Name, Country, Population FROM CapitalCity WHERE Continent = "Asia";
All three correct fields in the SELECT [1]
Keyword FROM [1]
Correct field in WHERE: Continent [1]
Correct value: "Asia" (single quotes also fine) [1]
▶ Topic lesson
A lesson on this topic · by Mr Bulmer's Learning Zone. Tap the picture to open it on YouTube.
Solutions follow the official Cambridge mark schemes; marks are shown in grey. Videos are from other YouTube channels. Paper codes read component / series / year: M/J = May/June, O/N = October/November. Past-paper questions © UCLES, reproduced for classroom practice.