Thursday, July 1, 2010

Normalization


Definition: A process of organizing the data in the most efficient way
Benefits:
  1. Eliminate data redundancy
  2. Improve performance
  3. Query optimization
  4. Faster update due to less number of columns in one table
  5. Index improvement
1st NF:
  1. Removes      repetitive groups
  2. Create a PK




2nd NF:
  1. Should be in 1st NF
  2. Remove   columns which create duplicate data in a table and creates a new table with Primary Key – Foreign Key relationship



3rd NF:
  1. Should be in 2nd NF
  2. Remove those non-key attributes (which are not PK) which can be derived from other non-key attributes.
Country can be derived from State also… so removing country





BCNF NF:
  1. Should be in 3rd NF
  2. If PK is composed of multiple columns then all non-key attribute should be derived from FULL PK only. If some non-key attribute can be derived from partial PK then remove it


4 comments:

  1. good publish.........very good for freshers to understand

    ReplyDelete
  2. Thanks buddy. I did this *years* ago and inherently do every time I design but needed a quick refresher on what happened in each stage and yours is the best example I have found.
    Cheers,

    Dave

    ReplyDelete
  3. very helpful thnx

    ReplyDelete