From 5e5713b90f68f03f8f2332a3565ace5bb0003824 Mon Sep 17 00:00:00 2001 From: Sarah Hoffmann Date: Wed, 7 Jun 2017 23:19:56 +0200 Subject: [PATCH] Ignore postcodes with comma and semicolon when computing address OSM has sometimes postcode lists for cities which should simply be ignored. Fixes #673. --- sql/functions.sql | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/sql/functions.sql b/sql/functions.sql index 1d83e653..77af9263 100644 --- a/sql/functions.sql +++ b/sql/functions.sql @@ -2420,7 +2420,7 @@ BEGIN IF searchpostcode IS NOT NULL and location.type = 'postcode' THEN location.isaddress := FALSE; END IF; - IF searchpostcode IS NULL and location.isaddress and location.type != 'postcode' and location.postcode IS NOT NULL THEN + IF searchpostcode IS NULL and location.isaddress and location.type != 'postcode' and location.postcode IS NOT NULL and location.postcode not similar to '%(,|;)%' THEN searchpostcode := location.postcode; END IF; IF location.rank_address = 4 AND location.isaddress THEN -- 2.39.5