Skip to main content

Lossless and dependency preserving check 2

Short answer

The decompositon is not lossless; no chase row becomes all 'a' (missing C in R1,R3). It is not dependency preserving because AB → C, AC → B, and BC → A are lost.

R = (A, B, C, D, E, G), R1 (A, B), R2 (B, C), R3 (A, B, D, E), R4 (E, G). F = {AB → C, AC → B, AD → E, B → D, BC → A, E → G}. Check whether the decomposition is lossless and dependency preserving.

R = (A, B, C, D, E, G); R1 = (A, B), R2 = (B, C), R3 = (A, B, D, E), R4 = (E, G). F = {AB → C, AC → B, AD → E, B → D, BC → A, E → G}.

Lossless join test (chase)

Rows are the relations, columns the attributes. a = distinguished value, b = unknown value.

Initial table:

ABCDEG
R1aabbbb
R2baabbb
R3aabaab
R4bbbbaa
  1. AB → C: R1 and R3 agree on A, B. Make their C equal (b13). R1 and R3 still have no "a" in C.
  2. B → D: R1, R2, R3 all have B = a. R3 has D = a, so D becomes a in R1 and R2.
  3. AD → E: R1 and R3 agree on A and D (both a). R3 has E = a, so R1's E becomes a.
  4. E → G: R1, R3, R4 have E = a. R4 has G = a, so G becomes a in R1 and R3.
  5. AC → B, BC → A: no new rows agree on their left sides (only R1 and R3 share A and C, and their B is already a). No further change.

Final table:

ABCDEG
R1aabaaa
R2baaabb
R3aabaaa
R4bbbbaa

No row is all "a" (R1 and R3 are missing C).

The decomposition is NOT lossless.

Dependency preservation test

Projections:

  • R1 (A, B): no non-trivial FD (A⁺ = A, B⁺ = BD).
  • R2 (B, C): no non-trivial FD.
  • R3 (A, B, D, E): B → D, AD → E (and AB → DE, which follows).
  • R4 (E, G): E → G.

FD by FD:

  • AD → E: in R3. Preserved.
  • B → D: in R3. Preserved.
  • E → G: in R4. Preserved.
  • AB → C: start Z = {A, B}. R3: Z ∩ R3 = AB, (AB)⁺ ∩ R3 = ABDE, so Z = ABDE. R4: E⁺ ∩ R4 = EG, so Z = ABDEG. R1 and R2: Z ∩ R2 = {B}, B⁺ ∩ R2 = {B}; nothing new. C is never reached. Lost.
  • AC → B: start Z = {A, C}. R1 gives A⁺ ∩ R1 = {A}, R2 gives C⁺ ∩ R2 = {C}, R3 gives {A}, R4 nothing. A and C are never together in one relation, so B is never reached. Lost.
  • BC → A: start Z = {B, C}. R2: (BC)⁺ ∩ R2 = {B, C}; R3: B⁺ ∩ R3 = {B, D}, so Z = BCD; R1 and R4 add nothing. A is never reached. Lost.

The decomposition is NOT dependency preserving (AB → C, AC → B, BC → A are lost).

Answer: not lossless and not dependency preserving.

✓ Answer checked by Claude Opus 5.5 (high effort)

All Database Management System chapter 4 questions →