Mercurial > gemma
diff schema/tap_tests_data.sql @ 2688:d316a6e41f54
Test if overlapping axis chunks are sewed together correctly
Currently this is ensured by ST_SimplifyPreserveTopology.
Imprecise buffering results made it necessary to introduce another cleaning
step in the simulation of waterway area for the test data.
author | Tom Gottfried <tom@intevation.de> |
---|---|
date | Fri, 15 Mar 2019 16:35:08 +0100 |
parents | 79f4a20e31c2 |
children | a2127495093e |
line wrap: on
line diff
--- a/schema/tap_tests_data.sql Fri Mar 15 15:59:40 2019 +0100 +++ b/schema/tap_tests_data.sql Fri Mar 15 16:35:08 2019 +0100 @@ -88,13 +88,17 @@ 4326), 'testriver' ), ( - ST_SetSRID(ST_CurveToLine('CIRCULARSTRING(0.6 0.4, 1 0, 1.5 0)'), 4326), + ST_SetSRID(ST_CurveToLine('CIRCULARSTRING(0.6 0.4, 1 0, 1.5 -0.00001)'), + 4326), 'testriver' ), ( ST_SetSRID('LINESTRING(0.5 0.5, 1 1)'::geometry, 4326), 'testriver' ), ( - ST_SetSRID('LINESTRING(1.5 0.00001, 2 0)'::geometry, 4326), + ST_SetSRID('LINESTRING(1.5 0, 1.55001 0)'::geometry, 4326), + 'testriver' +), ( + ST_SetSRID('LINESTRING(1.55 0, 2 0)'::geometry, 4326), 'testriver' ); @@ -113,8 +117,13 @@ FROM cleaned, buffer WHERE id <> ALL(ids) ORDER BY id ASC, ids DESC - FETCH FIRST ROW ONLY)) -INSERT INTO waterway.waterway_area (area) SELECT cbuf FROM cleaned; + FETCH FIRST ROW ONLY)), +cleaned1 AS ( + SELECT geom + FROM (SELECT (ST_Dump(cbuf)).geom FROM cleaned) AS dmp, + waterway.waterway_axis + WHERE ST_Intersects(geom, wtwaxs)) +INSERT INTO waterway.waterway_area (area) SELECT geom FROM cleaned1; INSERT INTO users.templates (template_name, country, template_data) VALUES ('AT', 'AT', '\x'), ('RO', 'RO', '\x');