Stav Alfi
Stav Alfi

Reputation: 13923

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?

Upvotes: 1

Views: 248

Answers (2)

Andy
Andy

Reputation: 3743

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.

Upvotes: 3

user7571182
user7571182

Reputation:

Both are Similar statements but the second one is ameliorated and therefore much more fascinating.

Specifically: a relation is in 2NF if it is in 1NF and no non-prime attribute is dependent on any proper subset of any candidate key of the relation. A non-prime attribute of a relation is an attribute that is not a part of any candidate key of the relation.

A candidate key is a Super Key from which no more Attribute can be pruned.

The highlighted part gives the conclusion that The database is in 2NF form(that was your first excerpt)

Upvotes: 0

Related Questions