Junior — Middle
Explain the concept of the third normal form in relational databases and why it is needed.
sobes.tech AI
Answer from AI
The Third Normal Form (3NF) is a normalization rule for relational databases that requires all non-key attributes to be directly dependent only on the primary key, and not on other non-key attributes. In other words, there should be no transitive dependencies in the table.
Why is 3NF needed:
- It reduces data redundancy.
- It prevents anomalies during update, insertion, and deletion.
- It ensures data integrity.
Example: if a table has fields {Student_ID, Student_Name, Faculty_Name, Dean_of_Faculty}, where Dean depends on Faculty_Name, and not directly on Student_ID, then this violates 3NF. To bring it to 3NF, the faculty should be separated into a separate table.