Skip to main content
Engineering LibreTexts

12.4: Normalization and Database Design

  • Page ID
    92195
  • \( \newcommand{\vecs}[1]{\overset { \scriptstyle \rightharpoonup} {\mathbf{#1}} } \) \( \newcommand{\vecd}[1]{\overset{-\!-\!\rightharpoonup}{\vphantom{a}\smash {#1}}} \)\(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\) \(\newcommand{\id}{\mathrm{id}}\) \( \newcommand{\Span}{\mathrm{span}}\) \( \newcommand{\kernel}{\mathrm{null}\,}\) \( \newcommand{\range}{\mathrm{range}\,}\) \( \newcommand{\RealPart}{\mathrm{Re}}\) \( \newcommand{\ImaginaryPart}{\mathrm{Im}}\) \( \newcommand{\Argument}{\mathrm{Arg}}\) \( \newcommand{\norm}[1]{\| #1 \|}\) \( \newcommand{\inner}[2]{\langle #1, #2 \rangle}\) \( \newcommand{\Span}{\mathrm{span}}\)\(\newcommand{\AA}{\unicode[.8,0]{x212B}}\)

    During the normalization process of database design, make sure that proposed entities meet required normal form before table structures are created. Many real-world databases have been improperly designed or burdened with anomalies if improperly modified during the course of time. You may be asked to redesign and modify existing databases. This can be a large undertaking if the tables are not properly normalized.

     

    Key Terms and Abbrevations

    Boyce-Codd normal form (BCNF):  a special case of 3rd NF

    first normal form (1NF): only single values are permitted at the intersection of each row and column so there are no repeating groups

    normalization: the process of determining how much redundancy exists in a table

    second normal form (2NF): the relation must be in 1NF and the PK comprises a single attribute

    semantic rules: business rules applied to the database

    third normal form (3NF): the relation must be in 2NF and all transitive dependencies must be removed; a non-key attribute may not be functionally dependent on another non-key attribute

     

    Exercises

    Complete chapters 11 and 12 before doing these exercises.

    1. What is normalization?
    2. When is a table in 1NF?
    3. When is a table in 2NF?
    4. When is a table in 3NF?
    5.  Identify and discuss each of the indicated dependencies in the dependency diagram shown in Figure \(\PageIndex{1}\).
      Ch11-Exercises -Fig11-1
      Figure \(\PageIndex{1}\) For question 5, by A. Watt.
    6. To keep track of students and courses, a new college uses the table structure in Figure \(\PageIndex{2}\).
      Draw the dependency diagram for this table.

       

      Ch11-Exercises -Fig11-2
      Figure 12.3 \(\PageIndex{2}\): For question 6, by A. Watt.
    7. Using the dependency diagram you just drew, show the tables (in their third normal form) you would create to fix the problems you encountered. Draw the dependency diagram for the fixed table.
    8. An agency called Instant Cover supplies part-time/temporary staff to hotels in Scotland. Figure \(\PageIndex{3}\) lists the time spent by agency staff working at various hotels. The national insurance number (NIN) is unique for every member of staff. Use Figure \(\PageIndex{3}\) to answer questions (a) and (b).
      Ch12-Exercises -Fig12-1
      Figure \(\PageIndex{3}\): For question 8, by A. Watt.
      1. This table is susceptible to update anomalies. Provide examples of insertion, deletion and update anomalies.
      2. Normalize this table to third normal form. State any assumptions.
    9. Fill in the blanks:
      1. ____________________ produces a lower normal form.
      2. Any attribute whose value determines other values within a row is called a(n) ____________________.
      3. An attribute that cannot be further divided is said to display ____________________.
      4. ____________________ refers to the level of detail represented by the values stored in a table’s row.
      5. A relational table must not contain ____________________ groups.

      Also see Appendix B: Sample ERD Exercises


    12.4: Normalization and Database Design is shared under a not declared license and was authored, remixed, and/or curated by LibreTexts.

    • Was this article helpful?