C170 Database Applications TASK 1
A. Construct a normalized physical database model A-1 Complete the 2NF To obtain the second normal form (2NF) for the original table, it was necessary to create three tables: Bagel Order, Bagel Order Line Item, and Bagel. This was required so the non-key attributes would functionally depend on the primary key. Bagel Order ID is the primary key for the Bagel Order table, as is Bagel ID in the Bagel table. The third table, Bagel Order Line Item, takes both primary keys in the tables as foreign keys. This table is also the associative table, also known as the intersection table, of Bagel Order and Bagel. The relationship of Bagel Order and Bagel Order Line item from left to right is many-to-one. While being read from right to left, the association is one-to-many. This is because many order line items can be placed in one Bagel Order, and a Bagel Order must contain, at least but not limited to, one item for it to be an order. The cardinality when read is a many-to-one because of the relationship the two tables have. The relationships between Bagel and Bagel Order Line Item are also many-to-one while being read from left to right and one-to-many in the opposite direction. A bagel can appear as a line item in multiple orders, but the order line needs to contain one or numerous bagels. When the cardinality is read from left to right, it is one-to-many.
Document information
- Uploaded on
- February 22, 2023
- Number of pages
- 13
- Written in
- 2022/2023
- Type
- Exam (elaborations)
- Contains
- Questions & answers