In my previous article i have given the information about First Normal Form with real life examples.In this article i would like to give you Second Normal Form with real life industry examples. We need to check all the normal forms to make your database normalized.This article gives you information about 2NF in depth.The Second Normal Form data must be in First normal form and all non-key attributes are fully functional dependent on the primary key.
In this section I would like to explain the Second Normal Form with real life examples.The data is in 2NF if following conditions are completed by data :
1.The data should be in First Normal Form (1 NF)
2.The data is in 2NF where data does not have any non-prime attribute which is dependent on any of proper subset of any candidate key of the relation.
Normalization is the process of organizing the data in a database so that it will meet following requirements :
1.There is no redundancy of data.
2.Data dependencies are logical.
The data is said to be in 2NF If,
1.It is in First normal form
2.There should not be any partial dependency of any column on primary key.Means the table have concatanated primary key and each attribute in table depends on that concatanated primary key.
3.All Non-key attributes are fully functionally dependent on primary key.If primary is is not composite key then all non key attributes are fully functionally dependent on primary key.
Example:
Let us consider following table which is in first normal form:
Employee No | Department No | Employee Name | Department |
1 | 101 | Ram | ORACLE |
2 | 102 | Rajiv | SQL |
3 | 101 | Shiva | PL SQL |
In above example we can see that department .Here We will see that there is composite key as{ Employee No,Department No}.Employee No is dependent on Employee Name and Department is dependent on Department No.We can split the above table into 2 different tables:
Table 1:Employee_NO table
Employee No | Department No | Employee Name |
1 | 101 | Ram |
2 | 102 | Rajiv |
3 | 101 | Shiva |
Table 2:Department table
Department No | Department |
101 | ORACLE |
102 | SQL |
Now we have simplified the table in to 2NF where each entity of table is functionally dependent on primary key.
I hope you like this article on 2NF. If you like this article or if you have any issues with the same kindly comment in to comments section.
In my previous article I have given details about application support engineer day to day…
In my previous articles I have given the roles and responsibilities of L1,L2 and L3…
In my previous articles i have given the hierarchy of production support in real company…
In this article i would like to provide information about production support organization structure or…
In my previous article I have given roles for L1 and L2 support engineer with…
I have started this new series of how to become application support engineer. This article…