...
Operating-Systems
January 19, 2024
Operating-Systems
January 20, 2024
Operating-Systems
January 19, 2024
Operating-Systems
January 20, 2024

Database-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?
A
D1is a lossy decomposition, but D2is a lossless decomposition.
B
Both D1and D2are lossy decompositions.
C
Both D1and D2are lossless decompositions.
D
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.
0 0 votes
Article Rating
Subscribe
Notify of
0 Comments
Inline Feedbacks
View all comments
0
Would love your thoughts, please comment.x
()
x
error: Alert: Content selection is disabled!!