Operating-Systems
January 19, 2024Operating-Systems
January 20, 2024Database-Management-System
Question 3 |
Consider the relation R(P, Q, S, T, X, Y, Z, W) with the following functional dependencies
Consider the decomposition of the relation R into the consistent relations according to the following two decomposition schemes.
D1: R=[(P,Q,S,T); (P,T,X); (Q,Y); (Y,Z,W)]
D2: R=[(P,Q,S);(T,X);(Q,Y);(Y,Z,W)]
Which one of the following options is correct?
Consider the decomposition of the relation R into the consistent relations according to the following two decomposition schemes.
D1: R=[(P,Q,S,T); (P,T,X); (Q,Y); (Y,Z,W)]
D2: R=[(P,Q,S);(T,X);(Q,Y);(Y,Z,W)]
Which one of the following options is correct?
D1is a lossy decomposition, but D2is a lossless decomposition.
| |
Both D1and D2are lossy decompositions. | |
Both D1and D2are lossless decompositions. | |
D1is a lossless decomposition, but D2is a lossy decomposition. |
Question 3 Explanation:
Given functional dependencies set:
PQ->X
P->YX
Q->Y
Y->ZW
- While merging the tables there should be some common attribute(s) and it should be a candidate key of one of the tables.
- R1 should be merged with R2 because PT is a key of R2.
- R3 should be merged with PQSTX because Q is a key of R3.
- R4 should be merged with PQSTXY because Y is a key of R4.
- R1 should be merged with R3 because Q is a key of R3.
- R4 should be merged with PQSY because Y is a key of R4.
- Now, there is no common attribute in between R2(TX) and PQSYZW.
- Hence, D2 is lossy decomposition.
Correct Answer: D
Question 3 Explanation:
Given functional dependencies set:
PQ->X
P->YX
Q->Y
Y->ZW
- While merging the tables there should be some common attribute(s) and it should be a candidate key of one of the tables.
- R1 should be merged with R2 because PT is a key of R2.
- R3 should be merged with PQSTX because Q is a key of R3.
- R4 should be merged with PQSTXY because Y is a key of R4.
- R1 should be merged with R3 because Q is a key of R3.
- R4 should be merged with PQSY because Y is a key of R4.
- Now, there is no common attribute in between R2(TX) and PQSYZW.
- Hence, D2 is lossy decomposition.
Subscribe
Login
0 Comments