3NF Vs 2NF, which is more strict

normalization

Which of these is true:

  1. If a table is in 2nd normal-form then it must be in 3rd normal-form.
  2. If a table is in 3rd normal-form then it must be in 2nd normal-form.

I know only one of them is correct, if it's the first it makes sense. If it's the second -doesn't make any sense to me. Maybe an example?

Best Answer

A database in 3NF is in 2NF also. A simple mnemonic is:

  • The key
  • The whole key
  • and nothing but the key
  • So help me Codd

2NF states that a table contains no fields that are logically a function of a part of the primary key. 3NF states that a table contains no fields that are logically a function of any field of the table but the 'whole' key. 3NF can be viewed as a specialisation of 2NF.