A relational database, GARDEN, has the following tables: OWNER(OwnerID, FirstName, TelephoneNo, TreeID, TreePosition) TREE(TreeID, ScientificName, MaxHeight, FastGrowing)
- (a)The database is not in Third Normal Form (3NF). Explain how the database can be normalised to 3NF.[3]
- (b)Write the Structured Query Language (SQL) script to add a new record in the table TREE to store the following data: [Table: Attribute, Value (TreeID: LOW_1276, ScientificName: Salix_Alba, MaxHeight: 30.00, FastGrowing: TRUE)][3]
- (c)State what is meant by a candidate key in a relational database.[1]
- (d)(i)Describe, using an example, what is meant by a data dictionary.[2]
- (d)(ii)Describe what is meant by a logical schema.[2]
Mark scheme
Marking points from the official mark scheme (Oct/Nov 2022). The mark or mark type is shown in brackets.
- [1] Solution 1: removing the many-to-many relationship between Owner and Tree
- [1] by removing TreeID and TreePosition from the Owner table
- [1] and creating a linking table between Owner and Tree
- [1] that contains OwnerID, TreeID and TreePosition
- [1] (composite) primary key of the linking table should be OwnerID and TreeID // insert a named new primary key in the linking table
- [1] Solution 2: removing the many-to-many relationship between Owner and Tree
- [1] move TreePosition into TREE table
- [1] put OwnerID into TREE table
- [1] create a new table with suitable name (for the species of tree)
- [1] containing ScientificName, MaxHeight and FastGrowing
- [1] with ScientificName as primary key // or another suitable primary key
- [1] INSERT INTO TREE
- [1] VALUES () and correct values
- [1] Values in correct order
- [1] Option 1: INSERT INTO TREE(TreeID, ScientificName, MaxHeight, FastGrowing) VALUES('LOW_1276', 'Salix_Alba', 30.00, TRUE);
- [1] Option 2: INSERT INTO TREE VALUES('LOW_1276', 'Salix_Alba', 30.00, TRUE);
- [1] An attribute / field (or set of attributes / fields) that could be a primary key
- [1] stores metadata about the database
- [1] For example: field / attribute names
- [1] table name
- [1] validation rules
- [1] data types
- [1] primary keys // foreign keys
- [1] relationships
- [1] the overview of a database structure
- [1] models the problem / situation
- [1] by using methods such as an ER diagram
- [1] independent of any particular DBMS
Write your answer and get it marked
On Oracle Prep you can write or photograph your own answer and have it marked by AI against this mark scheme, with feedback on what you missed.
Sign up free →