Skip to content

Commit

Permalink
fix(restrictions): wrong data types
Browse files Browse the repository at this point in the history
  • Loading branch information
azarz committed Sep 19, 2023
1 parent 90b9661 commit 346d024
Show file tree
Hide file tree
Showing 3 changed files with 16 additions and 15 deletions.
10 changes: 5 additions & 5 deletions r2gg/_pivot_to_pgr.py
Original file line number Diff line number Diff line change
Expand Up @@ -71,11 +71,11 @@ def pivot_to_pgr(source, cost_calculation_file_path, connection_work, connection
urbain boolean,
acces_pieton text,
nature_de_la_restriction text,
restriction_de_hauteur text,
restriction_de_poids_total text,
restriction_de_poids_par_essieu text,
restriction_de_largeur text,
restriction_de_longueur text,
restriction_de_hauteur double precision,
restriction_de_poids_total double precision,
restriction_de_poids_par_essieu double precision,
restriction_de_largeur double precision,
restriction_de_longueur double precision,
matieres_dangereuses_interdites boolean,
cpx_gestionnaire text,
cpx_numero_route_europeenne text,
Expand Down
11 changes: 6 additions & 5 deletions sql/bdtopo_v3.3.sql
Original file line number Diff line number Diff line change
Expand Up @@ -74,11 +74,11 @@ CREATE TABLE IF NOT EXISTS {output_schema}.edges (
urbain boolean,
acces_pieton text,
nature_de_la_restriction text,
restriction_de_hauteur text,
restriction_de_poids_total text,
restriction_de_poids_par_essieu text,
restriction_de_largeur text,
restriction_de_longueur text,
restriction_de_hauteur double precision,
restriction_de_poids_total double precision,
restriction_de_poids_par_essieu double precision,
restriction_de_largeur double precision,
restriction_de_longueur double precision,
matieres_dangereuses_interdites boolean,
cpx_gestionnaire text,
cpx_numero_route_europeenne text,
Expand Down Expand Up @@ -162,6 +162,7 @@ CREATE TEMP TABLE IF NOT EXISTS bduni_troncon AS
t.sens_de_circulation as sens_de_circulation,
(CASE
WHEN t.vitesse_moyenne_vl=1 THEN 0
WHEN t.vitesse_moyenne_vl IS NULL THEN 0
ELSE t.vitesse_moyenne_vl::integer
END) as vitesse_moyenne_vl,

Expand Down
10 changes: 5 additions & 5 deletions sql/bduni_convert.sql
Original file line number Diff line number Diff line change
Expand Up @@ -73,11 +73,11 @@ CREATE TABLE IF NOT EXISTS {output_schema}.edges (
urbain boolean,
acces_pieton text,
nature_de_la_restriction text,
restriction_de_hauteur text,
restriction_de_poids_total text,
restriction_de_poids_par_essieu text,
restriction_de_largeur text,
restriction_de_longueur text,
restriction_de_hauteur double precision,
restriction_de_poids_total double precision,
restriction_de_poids_par_essieu double precision,
restriction_de_largeur double precision,
restriction_de_longueur double precision,
matieres_dangereuses_interdites boolean,
cpx_gestionnaire text,
cpx_numero_route_europeenne text,
Expand Down

0 comments on commit 346d024

Please sign in to comment.