Database Management
Accenture PrimermediumDatabase ManagementData Manipulation Language

DELETE FROM dept WHERE dept_id = 901; The above delete statement throws an integrity constraint error because a child record was found. What could we do to make the statement execute?

Answer options

A
Delete the child records first.
B
Use DROP TABLE instead.
C
Use TRUNCATE instead.
D
Add a NOT NULL constraint.

Correct answer: Delete the child records first.

Explanation

An integrity constraint error occurs when a parent record has child records. Delete children first or use ON DELETE CASCADE.

Related Accenture Database Management questions

Practice more Accenture Database Management questions

PrimerDumps has 1400+ primer questions, 2026 mocks and coding hands-on — all free.