October 12, 2023
October 12, 2023
October 12, 2023
GATE 2021 CS-Set-2
October 12, 2023
 Question 181

Let R (A, B, C, D) be a relational schema with the following functional dependencies:
A → B, B → C, C → D and D → B.

The decomposition of R into
(A, B), (B, C), (B, D)

 A gives a lossless join, and is dependency preserving B gives a lossless join, but is not dependency preserving C does not give a lossless join, but is dependency preserving D does not give a lossless join and is not dependency preserving
Question 181 Explanation:
(A, B) (B, C) – common attribute is (B) and due to B→C, B is a key for (B, C) and hence ABC can be losslessly decomposed into (A, B)and (B, C).
(A, B, C) (B, D) – common attributes is B and B→D is a FD (via B→C, C→D), and hence, B is a key for (B, D). So, decomposition of (A, B, C, D) into (A, B, C) (B, D) is lossless.
Thus the given decomposition is lossless.
The given decomposition is also dependency preserving as the dependencies A→B is present in (A, B), B→C is present in (B, C), D→B is present in (B, D) and C→D is indirectly present via C→B in (B, C) and B→D in (B, D).
Question 181 Explanation:
(A, B) (B, C) – common attribute is (B) and due to B→C, B is a key for (B, C) and hence ABC can be losslessly decomposed into (A, B)and (B, C).
(A, B, C) (B, D) – common attributes is B and B→D is a FD (via B→C, C→D), and hence, B is a key for (B, D). So, decomposition of (A, B, C, D) into (A, B, C) (B, D) is lossless.
Thus the given decomposition is lossless.
The given decomposition is also dependency preserving as the dependencies A→B is present in (A, B), B→C is present in (B, C), D→B is present in (B, D) and C→D is indirectly present via C→B in (B, C) and B→D in (B, D).
Article Rating
Subscribe
Notify of
Inline Feedbacks
0