-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
feat(pipeline) : Ensure the zone_diffusion_codes for DROM/COM
There were cases where we did have the zone_diffusion_code set to "97" which can't be right, as it would mean that a given service coyuld be available across the oceans. Let's fix it and set the correct, 3-digit department number. This will also enable their search as we now (since the "new" communes) search for a match agains commune.departement, which can be 3 digits. There is also now a complete data validation that leaves the errors as a specific table in the public_dbt_test__audit schema.
- Loading branch information
Showing
4 changed files
with
159 additions
and
57 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
13 changes: 13 additions & 0 deletions
13
pipeline/dbt/models/staging/decoupage_administratif/stg_decoupage_administratif__epcis.sql
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
WITH source AS ( | ||
{{ stg_source_header('decoupage_administratif', 'epcis') }} | ||
), | ||
|
||
final AS ( | ||
SELECT | ||
code AS "code", | ||
nom AS "nom" | ||
FROM source | ||
ORDER BY code | ||
) | ||
|
||
SELECT * FROM final |