Practice & Assessment
Test your understanding of Foundations of Database Design
Multiple Choice Questions
5A requirements document says "each employee belongs to one department, and each department has many employees." What type of relationship is this?
Which column choice is the safest surrogate primary key for a high-traffic orders table?
You need to store students enrolled in courses — a student can take many courses and a course can have many students. What is the correct structure?
What is the main risk of skipping the design phase and writing SQL tables directly from vague requirements?
In crow's foot notation, what does a line with a single vertical bar on one end and a crow's foot on the other end represent?
Coding Challenges
1Extract Entities from a Clinic Requirements Doc
Given the following requirement paragraph, write a plain-text list of: (1) all entities, (2) at least three attributes per entity, and (3) the relationship type between each pair of entities. Requirement: 'A clinic manages doctors and patients. Each patient can book multiple appointments with one or more doctors. Each appointment has a date, time, and status. Doctors have a specialization and a license number.' Identify at least 3 entities, define PKs for each, and specify all relationship cardinalities. Time estimate: 15 minutes.
Mini Project
ER Diagram for a Library Management System
Design a complete ER diagram for a public library. Requirements: Members borrow books; a book can have multiple authors; each borrow has a due date and return date; a member can have unpaid fines. Identify all entities, define a primary key for each, list at least four attributes per entity, specify every relationship with correct cardinality, and draw the diagram using dbdiagram.io or any drawing tool. Export as an image or DBML file.
