Question 1
What is a database?
-
An organised collection of related data
-
A single unstructured data file
-
A program that displays one record
-
A network that transfers data
Question 2
What is a record in a database table?
-
Row in a table
-
Column in a table
-
Query in SQL
-
Form in an app
Question 3
What is a field in a database table?
-
Column in a table
-
Row in a table
-
Table relationship
-
Primary key
Question 4
Which property must a primary key have?
-
A unique value for every record
-
A repeated value in related records
-
A text value in every record
-
A value copied from a foreign key
Question 5
What is a foreign key used for?
-
Linking a record to another table
-
Uniquely identifying every record in its table
-
Sorting records by one field
-
Checking a value against a range
Question 6
In SQL, which command retrieves data?
-
SELECT
-
UPDATE
-
DELETE
-
INSERT
Question 7
In SQL, which clause filters rows?
-
WHERE
-
ORDER BY
-
FROM
-
JOIN
Question 8
What is ORDER BY used for in SQL?
-
Sort results
-
Delete results
-
Count fields
-
Create tables
Question 9
What ordering does ASC specify?
-
Lowest to highest
-
Highest to lowest
-
Newest to oldest
-
Reverse alphabetical
Question 10
What ordering does DESC specify?
-
Highest to lowest
-
Lowest to highest
-
Oldest to newest
-
Alphabetical order
Question 11
What does WHERE YearGroup = 10 do in an SQL query?
-
Selects records for Year 10
-
Sorts records by year group
-
Changes every year group to 10
-
Adds a new Year 10 record
Question 12
Which clause sorts pupils alphabetically by surname?
-
ORDER BY Surname ASC
-
ORDER BY Surname DESC
-
WHERE Surname = 'ASC'
-
SELECT ASC(Surname)
Question 13
Which SQL command adds a new record to a table?
-
INSERT INTO
-
UPDATE
-
DELETE FROM
-
ORDER BY
Question 14
What does AND mean in an SQL condition?
-
Both conditions must be true
-
Either condition can be true
-
No condition is checked
-
Rows are sorted descending
Question 15
When is an SQL condition joined by OR true?
-
When at least one condition is true
-
Only when both conditions are true
-
Only when exactly one condition is true
-
When both conditions are false
Question 16
What does INSERT INTO do?
-
Adds new records
-
Changes existing records
-
Removes existing records
-
Retrieves matching records
Question 17
What is UPDATE used for in SQL?
-
Change existing records
-
Creating a database
-
Delete a table
-
Count all rows
Question 18
What is DELETE used for in SQL?
-
Remove records
-
Add records
-
Encrypt records
-
Sort records
Question 19
Which field is the best primary key for a Customers table?
-
CustomerID
-
Surname
-
Town
-
DateOfBirth
Question 20
Which field in Orders should link each order to Customers?
-
CustomerID
-
OrderDate
-
Quantity
-
DeliveryTown
Question 21
Which query removes pupil 42 without deleting other pupils?
-
DELETE FROM Pupils WHERE PupilID = 42
-
DELETE FROM Pupils
-
UPDATE Pupils WHERE PupilID = 42
-
DELETE PupilID = 42 FROM Pupils
Question 22
What is an entity in database design?
-
A real-world object stored as data
-
One property stored in a field
-
One row returned by a query
-
A rule that validates input
Question 23
Which SQL keyword names the table used by a SELECT query?
-
FROM
-
WHERE
-
ORDER BY
-
UPDATE
Question 24
Which example is a one-to-many relationship?
-
One customer placing several orders
-
One pupil having one candidate number
-
Several pupils joining several clubs
-
Several doctors treating several patients
Question 25
What does a database field's data type specify?
-
The kind of value it can store
-
Whether its value must be unique
-
Which table it links to
-
How its records are sorted