Cambridge AS Level Computer Science 9618 · 8.1 Database Concepts

Q5 · 9618/12/O/N/22 Q5

Worked solution from the Databases Paper 1 Theory Fundamentals booklet, Part 1 of 2.

Q59618/12/O/N/22original Q5Structured · 11 marks
Question 5 from 9618/12/O/N/22

Worked solution

(a)

The problem is a many-to-many link between OWNER and TREE. Fix it with a linking table. Any three points:

Remove the many-to-many relationship between OWNER and TREE. [1]

Remove TreeID and TreePosition from OWNER. [1]

Create a linking table that holds OwnerID, TreeID and TreePosition. [1]

Its primary key is OwnerID and TreeID together (or add a new named key).

Another accepted answer: move TreePosition and OwnerID into TREE, and make a new table for the tree species (ScientificName, MaxHeight, FastGrowing) with its own primary key.

(b)

INSERT INTO TREE
VALUES ('LOW_1276', 'Salix_Alba', 30.00, TRUE);

INSERT INTO TREE [1]

VALUES ( ) with the correct values [1]

Values in the correct order [1]

Naming the fields after the table name is also accepted.

(c)

A candidate key is a field (or set of fields) that could be used as the primary key. [1]

(d)(i)

A data dictionary stores metadata about the database. [1]

Example: field names (or table names, data types, validation rules, keys, relationships). [1]

(d)(ii)

A logical schema is an overview of the structure of the database. [1]

It models the problem by using methods such as an E-R diagram. [1]

It is independent of any particular DBMS.

KEY IDEARemove a many-to-many link by adding a linking table that holds the keys of both tables.
TOTAL 11 marks

Official mark scheme

Mark scheme for 9618/12/O/N/22 question 5
VIDEO
▶ Whole paper

Video solution of the whole paper · by Audere Prep. 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.