Database & Data Handling (NCCIA) MCQs
1999 MCQs is category mein available hain.
All MCQs in Database & Data Handling (NCCIA)
401 What is the effect of making a foreign key UNIQUE in a one-to-many design?
Explanation
A unique foreign key allows each parent to be referenced only once, changing a 1:N design into 1:1.
Last verified on 27-11-2026
402 Which referential action is best when a Department is deleted but its Employee records must be kept for payroll history?
Explanation
SET NULL preserves the employee rows without a department, while RESTRICT forces an explicit reassignment; CASCADE would destroy payroll history.
Last verified on 27-11-2026
403 A Product is discontinued and its Supplier is deleted. If Product.SupplierID has ON DELETE SET NULL, what is preserved?
Explanation
SET NULL keeps the child product data while removing the link to the deleted supplier.
Last verified on 27-11-2026
404 In a School, deleting a Teacher with ON DELETE RESTRICT on Class.TeacherID will do what if the teacher has classes?
Explanation
RESTRICT protects the classes, so the teacher cannot be removed while classes still depend on them.
Last verified on 27-11-2026
405 Which combination of actions is most common for a lookup table such as Status?
Explanation
Lookup values in use should not be deleted, but a corrected code should propagate, so RESTRICT on delete and CASCADE on update is a common pair.
Last verified on 27-11-2026
406 What is the first step before choosing a referential action for a new foreign key?
Explanation
Referential actions encode business policy, so the designer must first know whether child rows should be kept, deleted or blocked.
Last verified on 27-11-2026
407 A junction table Enrolment has ON DELETE CASCADE on both StudentID and CourseID. What happens when a Course is deleted?
Explanation
CASCADE on a junction foreign key removes only the links for the deleted side, not the entities themselves.
Last verified on 27-11-2026
408 Which statement about foreign keys and NULL is correct?
Explanation
NULL is the allowed exception to referential integrity, representing no relationship, while any actual value must point to a real parent.
Last verified on 27-11-2026
409 In an ER diagram, a relationship with attributes is best represented by what?
Explanation
When a relationship has attributes and identity, it is modelled as an associative entity so those attributes have a place to live.
Last verified on 27-11-2026
410 A Vehicle can have many ServiceRecords, and a ServiceRecord belongs to one Vehicle. Where is the foreign key?
Explanation
The many side, ServiceRecord, holds the foreign key to the one side, Vehicle.
Last verified on 27-11-2026