Database & Data Handling (NCCIA) MCQs
1999 MCQs is category mein available hain.
All MCQs in Database & Data Handling (NCCIA)
1071 What is the difference between a candidate key and an alternate key?
Explanation
Every alternate key is a candidate key, but the primary key is the candidate key that was chosen, while the rest become alternate keys.
Last verified on 27-11-2026
1072 How many alternate keys can a table have?
Explanation
A table may have no alternate keys or several, one for each candidate key not chosen as primary.
Last verified on 27-11-2026
1073 What does ON DELETE SET NULL do?
Explanation
ON DELETE SET NULL keeps the child rows but removes their link to the deleted parent.
Last verified on 27-11-2026
1074 Which property must a primary key always have?
Explanation
A primary key combines uniqueness with NOT NULL, so no two rows share it and no row lacks it.
Last verified on 27-11-2026
1075 Can a primary key value be changed after it is inserted?
Explanation
Primary keys can be updated in most systems, but changing one can break references unless ON UPDATE CASCADE or similar handling is used.
Last verified on 27-11-2026
1076 Which of the following can be a primary key?
Explanation
Only a unique, non-null column (or combination) qualifies as a primary key.
Last verified on 27-11-2026
1077 What is a composite primary key?
Explanation
A composite key uses several columns jointly to identify a row, as in (OrderID, ProductID).
Last verified on 27-11-2026
1078 In an OrderDetails table, (OrderID, ProductID) is the primary key. What does this mean?
Explanation
A composite key guarantees uniqueness of the combination, not of each column separately.
Last verified on 27-11-2026
1079 What is a foreign key used for?
Explanation
A foreign key ensures values in one table match existing primary key values in the referenced table.
Last verified on 27-11-2026
1080 A foreign key must reference:
Explanation
A foreign key can only reference a column (or set) that is unique in the parent table, normally its primary key.
Last verified on 27-11-2026