Search code examples
databasedatabase-normalization3nf

Are both definitions to 3NF equal?


From 3rd Normal Form Definition:

A database is in third normal form if it satisfies the following conditions:

  • It is in second normal form.
  • There is no transitive functional dependency.

By transitive functional dependency, we mean we have the following relationships in the table: A is functionally dependent on B, and B is functionally dependent on C. In this case, C is transitively dependent on A via B.

My lucturer gave us a second defenition for 3NF:

Non-prime attributes cannot depend on any set that isn't a super-key (transitive dependency).

Are both definitions to 3NF equal? Why?


Solution

  • Let's assume there exists an attribute X that depends on a set of attributes that is not a Super-Key. This would imply that the set that X depends on contains at least one attribute np1 that is NOT part of a Super-Key. But np1 will in turn depend on a Super-Key. Because np1 depends on the Super-Key, one (and only one) of the following will be true :

    A. X only depends on the Super-Key => this contradicts our initial assumption

    or

    B. X only depends on np1 => this introduces a transitive dependency

    If X would truly depend on both the SK and np1, then [SK, np1] would become a superkey - which is not possible.

    So the only possible conclusion is that the two definitions are equal.