ISC2 Certified Secure Software Lifecycle Professional (CSSLP) Practice Question
You are preparing a synthetic data set for system-integration testing of an e-commerce platform that stores customers, orders, and order_items linked through foreign-key constraints. Production data cannot be used, yet the automated test queries must still return valid results across joins. Which approach best ensures that the generated test data preserves referential integrity while avoiding disclosure of real customer information?
Populate each table with randomly generated rows independently, disabling foreign-key constraints during the load to avoid referential errors.
Copy production tables verbatim, then hash customer names and addresses while leaving all key columns unchanged.
Generate customer and order records first, capture their new primary keys, and use those keys when creating related order_items so every foreign-key reference resolves correctly.
Insert only order_items with placeholder foreign keys and rely on the database engine to create any missing parent rows automatically during testing.
To keep referential integrity, test data must respect the same parent-child relationships that exist in production. Creating the parent records first (for example, customers and their accounts or orders) and then re-using the actual primary-key values that were assigned to those parents when generating each related child row guarantees that every foreign-key reference points to a valid parent. Simply disabling constraints, hashing keys independently, or generating child rows with dummy or null foreign keys breaks the relationship links and can cause joins, cascades, and integrity checks in the test suite to fail. Therefore, systematically generating data in dependency order and propagating the real key values is the correct method.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
Why is referential integrity important in system-integration testing?
Open an interactive chat with Bash
What are foreign-key constraints, and how do they work?
Open an interactive chat with Bash
How does generating test data in dependency order ensure valid results across joins?
Open an interactive chat with Bash
ISC2 Certified Secure Software Lifecycle Professional (CSSLP)
Secure Software Testing
Your Score:
Report Issue
Bash, the Crucial Exams Chat Bot
AI Bot
Loading...
Loading...
Loading...
Pass with Confidence.
IT & Cybersecurity Package
You have hit the limits of our free tier, become a Premium Member today for unlimited access.
Military, Healthcare worker, Gov. employee or Teacher? See if you qualify for a Community Discount.
Monthly
$19.99
$19.99/mo
Billed monthly, Cancel any time.
3 Month Pass
$44.99
$14.99/mo
One time purchase of $44.99, Does not auto-renew.
MOST POPULAR
Annual Pass
$119.99
$9.99/mo
One time purchase of $119.99, Does not auto-renew.
BEST DEAL
Lifetime Pass
$189.99
One time purchase, Good for life.
What You Get
All IT & Cybersecurity Package plans include the following perks and exams .