Skip to content

9618 · 8.1

Database Concepts — practice questions

Practice and worked examples for 9618 Database Concepts. Short previews only — attempt the full question in MarkScheme against the official scheme.

Worked example 1

A vet clinic needs a simple database to keep track of pets. (a) Identify the main entity. (b) Suggest four suitable attributes for this entity, and state an appropriate data type for each. (c) Draw a table structure and provide one example record.

Show solution outline

(a) The main entity is 'Pet'. [1 mark]

(b) Suitable attributes could be:

  • PetID (e.g., Text or Autonumber) - To uniquely identify the pet.
  • PetName (e.g., Text) - The pet's name.
  • DateOfBirth (e.g., Date/Time) - The pet's date of birth.
  • Species (e.g., Text) - The type of animal, e.g., 'Dog', 'Cat'. [1 mark for each of two suitable attributes with data types]

(c) Example table structure and record:

Table: Pet

PetIDPetNameDateOfBirthSpecies
P001Fido15/06/2021Dog

[1 mark for table structure with correct headings, 1 mark for a valid example record]

Worked example 2

A college database has a TblStudent and a TblCourse. A student can enrol on many courses, and a course can have many students. (a) What type of relationship exists between TblStudent and TblCourse? (b) How would this relationship be implemented in a relational database? Name the table(s) and key fields required.

Show solution outline

(a) This is a many-to-many relationship. [1 mark]

(b) This must be implemented using a linking table. [1 mark]

A new table, for example TblEnrolment, would be created. [1 mark]

This table would contain two foreign keys:

  • StudentID (from TblStudent)
  • CourseID (from TblCourse) [1 mark for identifying both foreign keys]

The primary key for TblEnrolment would be a composite key made up of (StudentID, CourseID). [1 mark for concept of composite key]