CS FundamentalsVery hardGATE CS · DBMS
R(A, B, C, D, E, F) has functional dependencies F → E, E → BC, CE → F, C → F. Which of the following is the complete set of candidate keys of R?
- A. {ACD, ADE}
- B. {ACD, ADE, ADF}
- C. {ACD, ADE, ABCD}
- D. {ACD, ADE, ADF, CEF}
Correct answer: B. {ACD, ADE, ADF}
Attributes never on a right side (AD) must be in every key; extending them and testing closures gives exactly the minimal superkeys {ACD, ADE, ADF}. Each closure covers all of R and no proper subset does, so these are all the candidate keys.
More DBMS and SQL questions
- R(A, B) = {(2, 1), (2, 2), (3, 3), (3, 4)} and S(B, C) = {(1, 5), (2, 5), (3, 5), (3, 6), (3, 7)}. How many tuples does σ{R.B ≠ S.B}(R ×…
- Table Takes(sid, cid, marks) rows: (1, 'C1', 80), (1, 'C2', NULL), (2, 'C1', 65), (3, 'C2', 90), (3, 'C3', 75), (5, 'C1', 50). What does…
- Table Stu(sid, sname) rows: (1, 'Om'), (2, 'Pia'), (3, 'Raj'), (4, 'Sia'). Table Takes(sid, cid, marks) rows: (1, 'C1', 80), (1, 'C2'…
- Which set of relational algebra operators is a complete (minimal) basis from which the others can be expressed?
- A B-tree (not B+ tree) stores a record pointer with every key in every node. With 1024-byte blocks, 9-byte keys, 6-byte tree pointers and…
- Two transactions each read X = 100. T1 sets X = X − 30 and commits; then T2 sets X = X + 50 and commits. The final value is 150. Which…