15.1 Transformation

  • Each entity becomes a table.

  • Each attribute becomes a table column.

  • Assign each column a data type (varchar, int, text, blob, decimal,date)

  • Specify a Primary Key in each table

  • For the 1:1 relationship, copy the Primary Key of either table into another one, as a Foreign Key.

  • For the 1:m relationship, copy the Primary Key of Parent table into the Child table, as a Foreign Key.

  • For the m:n relationship, create an new (intermediate) table. In this case, the new table is a child generated from both parent tables. Thus, copy each parent key into the new child.

    • In specifics, copy the primary key from both participating tables into the new table. The copied keys become the Primary Key of the new table. Also, each copied key is the Foreign key in the new table, referencing one parent table.