📞 0339-0387701 (WhatsApp) Contact

« Back to Database & Data Handling (NCCIA)

Can an alternate key contain NULL values?

A. It is defined as allowing NULLs
B. Only if it is a foreign key
C. No, it must be unique and not null in practice if it is to identify rows ✅
D. Always

Correct Answer: C. No, it must be unique and not null in practice if it is to identify rows

Explanation

An alternate key is a candidate key, so it must be unique and, to serve as an identifier, should not contain NULLs; in SQL a UNIQUE column may allow one NULL in some systems, but a true candidate key is non-null.