Worked solution from the Databases Paper 1 Theory Fundamentals booklet, Part 1 of 2.
Draw two lines, each with a crow's foot at PLACEMENT, the table holding the foreign keys:
STUDENT to PLACEMENT: one-to-many [1]
COMPANY to PLACEMENT: one-to-many [1]
Write any two reasons:
There are no repeating groups of attributes [1]
There are no many-to-many relationships [1]
Also accepted: there are no partial key dependencies (no non-key or transitive dependencies). Any two points score.
DELETE FROM PLACEMENT WHERE Complete = TRUE;
DELETE FROM the correct table (PLACEMENT) [1]
The correct condition Complete = TRUE [1]
SELECT COUNT(CompanyID) AS TotalPlacements FROM PLACEMENT WHERE CompanyID = "NEAM" AND StudentID = "LDEA01" AND Complete = TRUE;
SELECT COUNT of a suitable field [1]
AS with a suitable name for the total [1]
FROM PLACEMENT WHERE with one correct condition [1]
Two AND clauses with the other two correct conditions [1]
Say what it means, then give an example from this database.
Referential integrity means every foreign key has a matching primary key, so related data in different tables is consistent and there are no "orphaned" records [1]
Example: CompanyID in PLACEMENT is a foreign key, so it must match a CompanyID in COMPANY [1]
Example: if a student is deleted from STUDENT, all records with that StudentID are deleted from PLACEMENT (cascade delete), or if a CompanyID changes in COMPANY it is changed in PLACEMENT too [1]
▶ Whole paper
Video solution of the whole paper · by MAK CS. 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.