A list of all the books in the 'Science Fiction' genre is needed from the database.
| BookID | Title | Genre | PublishedYear |
|---|---|---|---|
| 501 | Dune | Science Fiction | 1965 |
| 502 | Neuromancer | Science Fiction | 1984 |
| 503 | The Hobbit | Fantasy | 1937 |
| LoanID | BookID | BorrowerID |
|---|---|---|
| 7001 | 501 | 88 |
| 7002 | 503 | 89 |
| BorrowerID | FirstName | LastName |
|---|---|---|
| 88 | Arthur | Dent |
| 89 | Bilbo | Baggins |
The following SQL query is run to produce the list:
A BookID, Title, Genre FROM Book WHERE B
Some parts of the SQL inquiry have been replaced by labels A and B.
State the SQL statements or clauses that should have been written in place of the labels A and B.
25 exam-style questions on AQA GCSE Computer Science Structured query language (SQL). Each one has a worked solution and a mark scheme showing where the marks go.