fix(pipeline): align SEN column order across KS4 union branches
int_ks4_with_lineage.sql unions stg_ees_ks4 and stg_legacy_ks4 via `select *`, which PostgreSQL aligns positionally. stg_legacy_ks4 listed sen_support_pct before sen_ehcp_pct while stg_ees_ks4 lists sen_ehcp_pct before sen_support_pct, swapping the two values for legacy-sourced rows in marts.fact_ks4_performance. Reordered stg_legacy_ks4's final select to match. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0146VHeLAWjDVE2B5uU67jCB
This commit is contained in:
@@ -41,8 +41,8 @@ select
|
|||||||
|
|
||||||
-- SEN
|
-- SEN
|
||||||
null::numeric as sen_pct,
|
null::numeric as sen_pct,
|
||||||
{{ safe_numeric('sen_support_pct') }} as sen_support_pct,
|
|
||||||
{{ safe_numeric('sen_ehcp_pct') }} as sen_ehcp_pct,
|
{{ safe_numeric('sen_ehcp_pct') }} as sen_ehcp_pct,
|
||||||
|
{{ safe_numeric('sen_support_pct') }} as sen_support_pct,
|
||||||
|
|
||||||
-- Progress 8 banding & disadvantage gaps (not published in legacy format)
|
-- Progress 8 banding & disadvantage gaps (not published in legacy format)
|
||||||
null::text as progress_8_banding,
|
null::text as progress_8_banding,
|
||||||
|
|||||||
Reference in New Issue
Block a user