Study Guide Questions: 1) If X->Z and Y->Z, does XY->Z? If yes, explain why. If
ID: 3544521 • Letter: S
Question
Study Guide Questions:
1) If X->Z and Y->Z, does XY->Z? If yes, explain why. If no, give an example.
2) if XY -> Z, does X ->Z? If yes, explain why. If no, give an example.
Explanation / Answer
Compute the closure of the following set F of functional dependencies for relation schema R = {A, B, C, D, E}. A -> BC CD -> E B -> D E -> A List the candidate keys for R. Answer: A -> BC, B -> D so A -> D so A -> DC -> E therefore A -> ABCDE E -> A, A -> ABCDE, so E -> ABCDE CD -> E, so CD -> ABCDE B -> D, BC -> CD, so BC -> ABCDE Attribute closure: A -> ABCDE B -> BD C -> C D -> D E -> ABCDE AB -> ABCDE AC -> ABCDE AD -> ABCDE AE -> ABCDE BC -> ABCDE BD -> BD BE -> ABCDE CD -> ABCDE CE -> ABCDE DE -> ABCDE ABC -> ABCDE ABD -> ABCDE ABE -> ABCDE ACD -> ABCDE ACE -> ABCDE ADE -> ABCDE BCD -> ABCDE BDE -> ABCDE CDE -> ABCDE ABCD -> ABCDE ABCE -> ABCDE ABDE -> ABCDE ACDE -> ABCDE BCDE -> ABCDE The candidate keys are A, E, CD, and BC Any combination of attributes that includes those is a superkey.