diff --git a/layers/boundary/boundary.sql b/layers/boundary/boundary.sql index 55047ecd..f3c1f627 100644 --- a/layers/boundary/boundary.sql +++ b/layers/boundary/boundary.sql @@ -16,7 +16,6 @@ CREATE OR REPLACE VIEW boundary_z1 AS ( UNION ALL SELECT geometry, 4 AS admin_level, false AS disputed, false AS maritime FROM ne_50m_admin_1_states_provinces_lines - WHERE scalerank <= 2 ); @@ -43,29 +42,19 @@ CREATE OR REPLACE VIEW boundary_z4 AS ( UNION ALL SELECT geometry, 4 AS admin_level, false AS disputed, false AS maritime FROM ne_10m_admin_1_states_provinces_lines - WHERE scalerank <= 3 AND min_zoom <= 7 + WHERE min_zoom <= 5 UNION ALL SELECT geometry, admin_level, disputed, maritime FROM osm_border_linestring_gen10 WHERE maritime=true AND admin_level <= 2 ); --- etldoc: ne_10m_admin_0_boundary_lines_land -> boundary_z5 --- etldoc: ne_10m_admin_1_states_provinces_lines -> boundary_z5 -- etldoc: osm_border_linestring_gen9 -> boundary_z5 CREATE OR REPLACE VIEW boundary_z5 AS ( - SELECT geometry, 2 AS admin_level, false AS disputed, false AS maritime - FROM ne_10m_admin_0_boundary_lines_land - WHERE featurecla <> 'Lease limit' - UNION ALL - SELECT geometry, 4 AS admin_level, false AS disputed, false AS maritime - FROM ne_10m_admin_1_states_provinces_lines - WHERE scalerank <= 7 AND min_zoom <= 8 - UNION ALL SELECT geometry, admin_level, disputed, maritime FROM osm_border_linestring_gen9 - WHERE maritime=true AND admin_level <= 2 + WHERE admin_level <= 4 ); -- etldoc: osm_border_linestring_gen8 -> boundary_z6 diff --git a/layers/boundary/boundary.yaml b/layers/boundary/boundary.yaml index cbceaad0..ec57da08 100644 --- a/layers/boundary/boundary.yaml +++ b/layers/boundary/boundary.yaml @@ -2,9 +2,9 @@ layer: id: "boundary" description: | Contains administrative boundaries as linestrings. - Until z5 [Natural Earth data](http://www.naturalearthdata.com/downloads/) is used after which + Until z4 [Natural Earth data](http://www.naturalearthdata.com/downloads/) is used after which OSM boundaries ([`boundary=administrative`](http://wiki.openstreetmap.org/wiki/Tag:boundary%3Dadministrative)) - are present from z6 to z14 (also for maritime boundaries with admin_level <= 2 at z4 and z5). + are present from z5 to z14 (also for maritime boundaries with admin_level <= 2 at z4). OSM data contains several [`admin_level`](http://wiki.openstreetmap.org/wiki/Tag:boundary%3Dadministrative#admin_level) but for most styles it makes sense to just style `admin_level=2` and `admin_level=4`. fields: diff --git a/layers/boundary/etl_diagram.png b/layers/boundary/etl_diagram.png index 8f77d16a..12e4ceaf 100644 Binary files a/layers/boundary/etl_diagram.png and b/layers/boundary/etl_diagram.png differ