Merge pull request #601 from quaelnix/fix-st-area

Fix bug in exclusion of small water bodies
This commit is contained in:
afischerdev 2023-08-30 17:08:13 +02:00 committed by GitHub
commit 88ec15f1d6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -76,7 +76,7 @@ FROM
polygons p
WHERE
-- do not consider small surfaces
st_area (p.way) > 1000
st_area (st_transform (p.way, 4326)::geography) > 1000
AND p.natural IN ('water')
OR (p.landuse IN ('forest', 'allotments', 'flowerbed', 'orchard', 'vineyard', 'recreation_ground', 'village_green')
OR p.leisure IN ('garden', 'park', 'nature_reserve'));
@ -92,7 +92,7 @@ FROM
polygons p
WHERE
-- do not consider small surfaces
st_area (p.way) > 1000
st_area (st_transform (p.way, 4326)::geography) > 1000
AND p.natural IN ('water')
OR (p.landuse IN ('forest', 'allotments', 'flowerbed', 'orchard', 'vineyard', 'recreation_ground', 'village_green')
OR p.leisure IN ('garden', 'park', 'nature_reserve'));