Friday, 23 September 2011

Normalization

Normalization : In simple terms Normalization is the Best data formation of  the DataBase.

Normally we can achieve this Best Data Formation by
1NF (First Normal Form)           : Where we remove Duplication/Repetition of data
2NF (Second Normal Form)      : 1NF should be satisfied and along with it there should be
                                                    no "Partial Dependency" in data.
3NF (Third Normal Form)          : 2NF should be satisfied and along with it there should be
                                                    no "Transitive Dependency" in data.


         Partial Dependency – when an non-key attribute is determined by a part, but not the whole, of a    COMPOSITE primary key.

Transitive Dependency – when a non-key attribute determines another non-key attribute.



Lets Take some examples:
Example 1 : Determine NF



Here there is no partial dependency. So not in 2NF


As it is not in 2NF so can't achieve 3NF


Thus we can say that the relation is in 1NF only.




Bringing to Normalized Form.
Example 2:

 Bringing a relation to 1NF




 Bringing a relation to 2NF




 Bringing a relation to 3NF




 This is how we can format data using Normalized Form. 

Thanks,
Sudhir Bhilar





No comments:

Post a Comment