A single-table database is a tidy grid of records and fields, and SQL is the language we use to pull exactly the data we want out of it. In this lesson we cover the key database terms, why a primary key must be unique, and how to build a query with SELECT, FROM, WHERE and ORDER BY.
1. Which statement about a primary key is correct?
2. A Student table has fields StudentID, FirstName, Surname and FormClass. Which query lists the first name and surname of every student in class 11B, sorted by surname?
3. In a query, what does SELECT * mean?
4. Which SQL keyword decides which records are returned by testing a condition?
Practise real exam questions on this
Type your answer, see your mark against the mark scheme in seconds. Free, 5 a day.
Start practising →
Teaching this topic?
Mark your whole class's answers and see who's stuck, for £19 a month.
See the class plan →
Free revision content. Multiple-choice answers are marked instantly. Written answers are marked by AI on /free-mark.