Beyond BCNF

Outline

Data explosion problem

  • A relational schema
    EMP(employee-number, programming-language, operating-system)
    has no valid functional dependencies
  • A relational table EMPLOYEE over a relational schema EMP contains information about the programming langauges and operating systems know by employees
      employee-number     programming-language     operating-system
         200                     Python                  Linux
         200                     Java                    Linux
         200                     Scala                   Linux
         200                     Python                  Windows 10
         200                     Java                    Windows 10
         200                     Scala                   Windows 10
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

Data explosion problem

    • employee-number     programming-language     operating-system
         200                     Python                  Linux
         200                     Java                    Linux
         200                     Scala                   Linux
         200                     Python                  Windows
         200                     Java                    Windows
         200                     Scala                   Windows
         200                     Fortran                 Linux
         200                     Fortran                 Windows
         200                     Python                  Unix
         200                     Java                    Unix
         200                     Scala                   Unix
         200                     Fortran                 Unix
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

Data explosion problem

    • employee-number     programming-language     operating-system
         200                     Python                  Linux
         200                     Java                    Linux
         200                     Scala                   Linux
         200                     Python                  Windows
         200                     Java                    Windows
         200                     Scala                   Windows
         200                     Fortran                 Linux
         200                     Fortran                 Windows
         200                     Python                  Unix
         200                     Java                    Unix
         200                     Scala                   Unix
         200                     Fortran                 Unix
  • Normal form ?
  • No valid functional dependencies means that does not exists a functional dependence such that its left hand side is not a superkey
  • It means that no functional dependencies violate BCNF
  • BCNF but ... still a lot of redundancies !
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

Beyond BCNF

Outline

Multivalued dependency

  • Let R = ( A1 , ..., An ) be a relational schema and let X, Y, Z be nonempty subsets of R
  • We say that a multivalued dependency X →→ Y|Z is valid in relational schema R if ...
  • ... for any relational table r created over a relational schema R, if for any two rows v and w in r such that v[X] = w[X] there exist a row t in r such that ...
  • ... v[XY] = t[XY] and w[XZ] = t[XZ]
  • Other notation
      X  Y  
      X     Z
      -------
      X  Y  Z
  • It means that if a row X Y ▢ is in a relational table and a row X ▢ Z is in the same table then a row X Y Z must be in the same relational table
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

Multivalued dependency

  • Examples
  • employee-number →→ programming-language|operating-system
    • employee-number     programming-language   
      employee-number                              operating-system
      -------------------------------------------------------------
      employee-number     programming-language     operating-system
  • A person owns many cars and has many skills
  • first-name, last-name →→ registration-number|skill
  • A students has many friends and many hobbies
  • student-number →→ first-name, last-name|hobby
    • CREATE VIEW XY AS (SELECT X,Y FROM R);
      CREATE VIEW XZ AS (SELECT X,Z FROM R);
      SELECT XY.X, XY.Y, XZ.Z
      FROM XY JOIN XZ ON XY.X = XZ.X
  • The result of SELECT is always equal to R
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

Beyond BCNF

Outline

4NF

  • A relational schema R is in the Fourth Normal Form (4NF) if for every nontrivial multivalued dependency X →→ Y|Z a set of attributes X is a superkey in a relational schema R
  • Alternative definition:
  • A relational schema R is in 4NF if no nontrivial multivalued dependencies are valid in a relational schema R
  • A multivalued dependency
    employee-number →→ programming-language|operating-system
    is valid in a relational schema
    EMP(employee-number, programming-language, operating-system)
  • A relational schema EMP is NOT in 4NF becasuse a nontrivial multivalued dependency is valid in EMP
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

4NF

  • Decomposition into 4NF ?
  • EPGM(employee-number, programming-language),
    EOPS(employee-number, operating-system)
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

Beyond BCNF

Outline

Join dependency

  • Let R = ( A1 , ..., An ) be a relational schema and let X, Y1 , ... ,Yn be nonempty subsets of R
  • We say that join dependency ⋈(X, Y1 , ... ,Yn) is valid in a relational schema R if ...
  • ... for any relational table r with relational schema R, if for any n rows v1 , ... , vn in r such that v1[X] = ... = vn[X] there exist a row t in r such that ...
  • ... v1[XY1] = t[XY1 ] and ... and vn[XYn] = t[XYn]
  • Other notation
      X  Y1  
      X     Y2
      X        Y3
      ... ... ... ...
      X   ... ... ... YN
      ------------------
      X  Y1 Y2 Y3 ... YN
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

Join dependency

  • Examples
  • ⋈(employee-number, programming-language, operating-system, hobby)
    • employee-number     programming-language   
      employee-number                              operating-system
      employee-number                                                  hobby
      ----------------------------------------------------------------------
      employee-number     programming-language     operating-system    hobby
  • A person owns many cars and has many skills and has many employers
  • ⋈((first-name, last-name),registration-number, skill, employer)
    • CREATE VIEW XY1 AS (SELECT X,Y1 FROM R);
      CREATE VIEW XY2 AS (SELECT X,Y2 FROM R);
      ... ... ... ... ... ... ... ... ... ...
      CREATE VIEW XYN AS (SELECT X,YN FROM R);
      SELECT XY1.X, XY1.Y1, XY2.Y2, ... XYN.YN
      FROM XY1 JOIN XY2 ON XY1.X = XY2.X JOIN ... JOIN XYN ON XY1.X = XYN.X 
  • The result of SELECT is always equal to R
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

Beyond BCNF

Outline

5NF

  • A relational schema R is in the Fifth Normal Form (5NF) if for every nontrivial join dependency⋈(X, Y1 , ... ,Yn) a set of attributes X is a superkey in R
  • Alternative definition:
  • A relational schema R is in 5NF if no nontrivial join dependencies are valid in schema R
  • A join dependency ⋈(employee-number, programming-language, operating-system, hobby) is valid in a relational schema
    EMP(employee-number, programming-language, operating-system, hobby)
  • A relational schema EMP is NOT in 5NF because a nontrivial join dependency is valid in EMP
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

5NF

  • Decomposition into 5NF ?
  • EPGM(employee-number, programming-language),
    EOPS(employee-number, operating-system),
    EHOB(employee-number, hobby)
In HTML view press 'p' to see the lecture notes
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026

References

  • T. Connoly, C. Begg, Database Systems, A Practical Approach to Design, Implementation, and Management, Chapter 15.4 Fourth Normal Form (4NF), Chapter 15.5 Fifth Normal Form (5NF), Pearson Education Ltd, 2015
TOP              Created by Janusz R. Getta, CSCI235 Database Systems, Autumn 2026