(COMPLETE ANSWERS)
2025 (865742) - DUE 5
September 2025
For assistance contact
Email:
, 3NF and BCNF
A relation is in Third Normal Form (3NF) if it's in 2NF and there are no transitive
dependencies. A transitive dependency occurs when a non-prime attribute (an attribute not part
of the primary key) determines another non-prime attribute.
A relation is in Boyce-Codd Normal Form (BCNF) if every determinant is a candidate key. A
determinant is an attribute or set of attributes that determines another attribute. BCNF is a
stricter version of 3NF.
When 3NF is also BCNF
A relation in 3NF is also in BCNF if the only determinants are candidate keys. This is the most
common scenario.
Example:
Consider a table COURSES(CourseID, Instructor, InstructorEmail).
CourseID is the primary key.
CourseID determines Instructor.
Instructor determines InstructorEmail.
This table is in 3NF because there's a transitive dependency (CourseID -> Instructor ->
InstructorEmail). To get it to 3NF, you would decompose it into COURSES(CourseID,
Instructor) and INSTRUCTORS(Instructor, InstructorEmail). The INSTRUCTORS table now
has Instructor as its primary key, and it is a determinant for InstructorEmail. Instructor is a
candidate key, so the table is in BCNF.
When 3NF is NOT BCNF
A relation in 3NF is not in BCNF when it has overlapping candidate keys and a non-key
attribute is functionally dependent on a part of a candidate key. This situation is rare but
important to understand.
Example:
Let's use a class schedule scenario. CLASS_SCHEDULE(StudentName, Subject, Teacher)
A student can take multiple subjects.
A subject can be taught by multiple teachers.
A teacher can teach multiple subjects.
A student taking a specific subject is assigned to a specific teacher.