📞 0339-0387701 (WhatsApp) Contact

« Back to Database & Data Handling (NCCIA)

In a composite primary key (OrderID, ProductID), what does entity integrity require?

A. Both OrderID and ProductID must be non-null and the pair must be unique ✅
B. Only ProductID must be non-null
C. Only OrderID must be non-null
D. At least one of them must be non-null

Correct Answer: A. Both OrderID and ProductID must be non-null and the pair must be unique

Explanation

In a composite key, no part may be null and the whole combination must be unique, otherwise a row cannot be identified.