Skip to content

Commit

Permalink
solve minor typos
Browse files Browse the repository at this point in the history
  • Loading branch information
laurinehu authored and laurinehu committed Oct 24, 2023
1 parent f14bd47 commit b26f4a4
Show file tree
Hide file tree
Showing 4 changed files with 21 additions and 17 deletions.
27 changes: 13 additions & 14 deletions dbt/models/marts/suivi_cap_criteres.sql
Original file line number Diff line number Diff line change
@@ -1,17 +1,16 @@
select
criteres."nom" as "nom_critère",
criteres."id" as "id_critère",
criteres."niveau" as "niveau_critère",
-- REFUSED et REFUSED_2 correspondent au même état (?) - à confirmer par Zo
camp."nom" as "nom_campagne",
structs."id" as "id_structure",
structs."nom" as "nom_structure",
structs."nom_complet" as "nom_structure_complet",
structs."département" as "département",
structs."nom_département" as "nom_département",
structs."région" as "nom_région",
structs.bassin_d_emploi as bassin_d_emploi,
structs."type" as "type_structure",
criteres."nom" as "nom_critère",
criteres."id" as "id_critère",
criteres."niveau" as "niveau_critère",
camp."nom" as "nom_campagne",
structs."id" as "id_structure",
structs."nom" as "nom_structure",
structs."nom_structure_complet" as "nom_structure_complet",
structs."département" as "département",
structs."nom_département" as "nom_département",
structs."région" as "nom_région",
structs.bassin_d_emploi as bassin_d_emploi,
structs."type_struct" as "type_structure",
case
when
cap_criteres."état" = 'ACCEPTED'
Expand All @@ -33,7 +32,7 @@ select
cap_criteres."état" = 'PENDING' and cap_criteres."date_transmission" is null
then
'Non transmis'
end as "état"
end as "état"
from
{{ source('emplois', 'cap_critères_iae') }} as cap_criteres
left join {{ source('emplois', 'critères_iae') }} as criteres on cap_criteres."id_critère_iae" = criteres."id"
Expand Down
2 changes: 1 addition & 1 deletion dbt/models/marts/suivi_cap_structures.sql
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ select
cap_campagnes.nom as nom_campagne,
cap_structures.id_structure as id_cap_structure,
structures.id as id_structure,
structures.type as "type",
structures.type_struct as "type",
structures."département" as "département",
structures."nom_département" as "nom_département",
structures."région" as "région",
Expand Down
2 changes: 1 addition & 1 deletion dbt/models/staging/stg_candidatures.sql
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ select
except=["id", "date_mise_à_jour_metabase", "état", "motif_de_refus", "origine", "délai_de_réponse", "délai_prise_en_compte", "origine_détaillée"]) }},
{{ pilo_star(ref('stg_organisations'), except=["id", "date_mise_à_jour_metabase", "ville", "code_commune", "type", "date_inscription", "total_candidatures", "total_membres", "total_embauches", "date_derniere_candidature"], relation_alias='org_prescripteur') }},
candidatures.id as id,
struct.bassin_emploi_structure as bassin_emploi_structure,
struct.bassin_d_emploi as bassin_emploi_structure,
org_prescripteur.zone_emploi as bassin_emploi_prescripteur,
org_prescripteur.type as type_org_prescripteur,
org_prescripteur.date_inscription as date_inscription_orga,
Expand Down
7 changes: 6 additions & 1 deletion dbt/models/staging/stg_structures.sql
Original file line number Diff line number Diff line change
@@ -1,9 +1,14 @@
select
s.id as id,
s.nom as nom,
s.type as type_struct,
s.siret as siret,
s.active as active,
s.ville as ville,
insee_geo.nom_zone_emploi as bassin_emploi_structure,
s."département" as "département",
s."nom_département" as "nom_département",
s."région" as "région",
insee_geo.nom_zone_emploi as bassin_d_emploi,
s.nom_complet as "nom_structure_complet"
from
{{ source('emplois', 'structures') }} as s
Expand Down

0 comments on commit b26f4a4

Please sign in to comment.