Merge pull request #1394 from mtmail/update-postcodes-without-colon

exclude postcode ranges separated by colon from centre point calculation
This commit is contained in:
Sarah Hoffmann 2019-06-09 11:03:10 +02:00 committed by GitHub
commit 1f57d730df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -6,7 +6,7 @@ SELECT country_code,
ST_Centroid(ST_Collect(ST_Centroid(geometry))) as centroid
FROM placex
WHERE address ? 'postcode'
AND address->'postcode' NOT SIMILAR TO '%(,|;)%'
AND address->'postcode' NOT SIMILAR TO '%(,|;|:)%'
AND geometry IS NOT null
GROUP BY country_code, pc;