CS FundamentalsHardProduct-company MCQ pattern

R(A, B, C, D) has A as its only candidate key. How many superkeys does R have?

  1. A. 15
  2. B. 8
  3. C. 7
  4. D. 4

Correct answer: B. 8

Every superkey must contain A; each of B, C and D may be in or out: 2³ = 8 (A, AB, AC, AD, ABC, ABD, ACD, ABCD). 15 is the total number of non-empty subsets.

More DBMS and SQL questions

Exams that ask this topic