📞 0339-0387701 (WhatsApp) Contact

« Back to Database & Data Handling (NCCIA)

Which scenario best justifies a surrogate key?

A. A product table keyed by a supplier code that changes when the supplier changes ✅
B. A student table keyed by full name
C. A country table keyed by a two-letter ISO code that never changes
D. A small lookup table with five fixed values

Correct Answer: A. A product table keyed by a supplier code that changes when the supplier changes

Explanation

When the natural code is unstable, a surrogate key protects joins from change, while the supplier code stays as an ordinary unique attribute.