SQLMediumofficialBenchmark eligiblefree
Date dimension repair
fact_sales.date_text mixes ISO, US, and invalid strings. BI expects dim_date.date_key (YYYYMMDD integer). Quarantine unparseable dates; do not delete facts.
| Field | Detail |
|---|---|
| Creator | PipelineArena · expert |
| Version | 2.0.0 |
| Time | 40 min |
| Credits | 3 |
| Completion | 0% · 0.0 rating |
| Hidden tests | 5 |
Objective
Every parseable fact attaches to dim_date; invalid rows sit in fact_sales_rejected.
| # | Success condition |
|---|---|
| 1 | dim_date covers the documented range including fiscal week |
| 2 | Parseable facts have a valid date_key FK |
| 3 | Invalid dates are quarantined, not deleted |
| 4 | No silent NULL date_key on a parseable row |
| # | Visible instruction |
|---|---|
| 1 | Generate dim_date for the required range. |
| 2 | Parse known formats explicitly; fail closed on the rest. |
| 3 | Write rejects instead of dropping facts. |
Hidden tests score the final tables or files, not the exact syntax you used. Test implementation is never shown to participants.
Signed-in workspace: Open in app