Courseiva
mediumMultiple SelectObjective-mapped

FC0-U71 Practice Question: A database designer wants to enforce that a…

A database designer wants to enforce that a 'CustomerID' value in an 'Orders' table must exist in the 'Customers' table. Which TWO methods can achieve this?

⚠ Common exam trap

Candidates often confuse a primary key or unique constraint with referential integrity, thinking that ensuring uniqueness in the parent table automatically enforces existence in the child table, but neither does so without an explicit foreign key or trigger.

Answer choices

Why each option matters

Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.

Correct answer & explanation

Use a trigger to check existence

A trigger can be programmed to check, before an INSERT or UPDATE on the Orders table, whether the new CustomerID exists in the Customers table. If the value is not found, the trigger can roll back the transaction, enforcing referential integrity without using a formal foreign key constraint. This is a valid method in database systems that support procedural logic within triggers.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Create a unique constraint on Orders.CustomerID

    Why it's wrong here

    Ensures no duplicates, not existence.

  • Create an index on Orders.CustomerID

    Why it's wrong here

    Index improves performance, does not enforce.

  • Use a trigger to check existence

    Why this is correct

    A trigger can validate the CustomerID.

  • Create a primary key on Customers.CustomerID

    Why it's wrong here

    Ensures uniqueness but not reference.

  • Create a foreign key from Orders.CustomerID to Customers.CustomerID

    Why this is correct

    Foreign key enforces referential integrity.

About these practice questions

This FC0-U71 question is part of Courseiva's 988-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This FC0-U71 practice question is part of Courseiva's free CompTIA certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the FC0-U71 exam.