History Erased
A medium ai_coding interview practice problem on DataDriven. Write and execute real ai_coding code with instant grading.
- Domain
- ai_coding
- Difficulty
- medium
- Seniority
- L5
Problem
dim_customer is supposed to be SCD-2: every change to address/email creates a new row with effective_from / effective_to and is_current. After today's incremental run, the table has exactly one row per customer , history wiped. Run tests/test_scd2_history.py to reproduce. Fix sql/merge_dim_customer.sql so changes append a new version and close the old one, instead of overwriting.
Summary
Yesterday never happened.
Practice This Problem
Solve this ai_coding problem with real code execution. DataDriven runs your solution and grades it automatically.