CS FundamentalsVery hardProduct company interview · GATE level

R(A, B, C, D, E) has functional dependencies AB → C, C → D, D → E and E → A. Which statement is correct?

  1. A. 4 candidate keys; R is in 3NF but not BCNF, and only one of the given FDs violates BCNF
  2. B. 4 candidate keys; R is in BCNF
  3. C. 1 candidate key (AB); R is in 2NF but not 3NF
  4. D. 4 candidate keys; R is in 3NF but not BCNF, and three of the given FDs violate BCNF

Correct answer: D. 4 candidate keys; R is in 3NF but not BCNF, and three of the given FDs violate BCNF

B is on no right-hand side, so every key contains B. AB gives C, D, E: a key. BC gives D, E, A: a key. BD gives E, A, C: a key. BE gives A, C, D: a key. With keys AB, BC, BD and BE every attribute is prime, so no FD can break 3NF. For BCNF every determinant must be a superkey: AB is, but C, D and E alone are not, so C → D, D → E and E → A all violate BCNF. Stopping at the first key AB makes C → D look like a transitive dependency of a non-prime attribute, which is the trap behind the 2NF answer.

More DBMS and SQL questions

Exams that ask this topic