CS FundamentalsVery hardProduct company interview · GATE level

A relation R(A, B, C, D) has only the FD A → B (C and D are independent, part of the key). Decomposing R into R1(A, C) and R2(B, D) — is this decomposition lossless?

  1. A. Yes, every binary decomposition of a 4-attribute relation is automatically lossless
  2. B. It depends only on whether R1 or R2 has more attributes
  3. C. No; the common attributes of R1 and R2 are empty (no shared column at all), so the lossless-join test (common attributes must determine one full side) automatically fails unless that empty intersection trivially determines everything, which it cannot here
  4. D. Yes, because A → B still holds logically

Correct answer: C. No; the common attributes of R1 and R2 are empty (no shared column at all), so the lossless-join test (common attributes must determine one full side) automatically fails unless that empty intersection trivially determines everything, which it cannot here

R1(A, C) and R2(B, D) share NO attributes at all. The lossless-join test requires the intersection of the two decomposed schemas to functionally determine at least one of them entirely; an empty intersection can only do that if one side has no attributes, which isn't the case here — so this decomposition is lossy (rejoining R1 and R2 would produce a meaningless Cartesian-product-like blow-up, losing the original A-B-C-D associations).

More DBMS and SQL questions

Exams that ask this topic