DSA Factory
Free Keys, ER and normalization lessonsKeys, ER and normalization · Stage 1 · Modelling the real world · Step 2

From ER model to tables

Map entities, one-to-many, many-to-many and weak entities onto tables, keys and foreign keys. About 13 minutes.

Quick check

A person can have several phone numbers. Which table design stores this without repeating the person's other data?

  1. AA phone table with person_id and number, one row per number
  2. BColumns phone1, phone2, phone3 in person
  3. COne column holding the numbers separated by commas
Show the answer

A phone table with person_id and number, one row per number. A multi-valued attribute becomes a table of its own.

Lock it in

4 questions on this idea

Short questions that apply the idea to new cases: trace it, work out a number, put steps in order. A wrong answer explains itself.

Answer them in your browserFree account, no card. Your progress is saved, and the idea comes back in a quick review later.
Sign up free to solve