Skip to content

Commit

Permalink
ensure order of cdbg_zap_eligiblity records
Browse files Browse the repository at this point in the history
  • Loading branch information
damonmcc committed Jan 8, 2025
1 parent 601693b commit 842e454
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion products/cdbg/models/product/cdbg_zap_eligiblity.sql
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,10 @@ projects_eligibility AS (
),

zap_projects AS (
SELECT * FROM {{ ref("stg__zap_projects") }}
SELECT
ROW_NUMBER() OVER () AS project_row_number,
*
FROM {{ ref("stg__zap_projects") }}
),

project_lot_arrays AS (
Expand Down Expand Up @@ -80,6 +83,7 @@ original_order AS (
FROM zap_projects
LEFT JOIN eligiblity
ON zap_projects.project_id = eligiblity.project_id
ORDER BY project_row_number ASC
)

SELECT * FROM original_order

0 comments on commit 842e454

Please sign in to comment.