From: Sarah Hoffmann Date: Sat, 18 Apr 2015 16:40:31 +0000 (+0200) Subject: Merge remote-tracking branch 'upstream/master' X-Git-Tag: deploy~467 X-Git-Url: https://git.openstreetmap.org./nominatim.git/commitdiff_plain/158628553f39cf4508a54021af71bc4836e893e8?hp=-c Merge remote-tracking branch 'upstream/master' --- 158628553f39cf4508a54021af71bc4836e893e8 diff --combined sql/functions.sql index a5d0f6a0,658771b7..898cdb69 --- a/sql/functions.sql +++ b/sql/functions.sql @@@ -689,7 -689,7 +689,7 @@@ BEGI -- one with the smallest id because the original node was created first. -- Ignore all nodes marked for deletion. (Might happen when the type changes.) select * from placex where osm_type = 'N' and osm_id = waynodes[nodeidpos]::BIGINT - and indexed_status < 100 + and indexed_status < 100 and housenumber is not NULL order by (type = 'address'),place_id limit 1 INTO nextnode; IF nextnode.place_id IS NOT NULL THEN @@@ -2035,12 -2035,6 +2035,12 @@@ BEGI END IF; + -- refuse to update multiplpoygons with too many objects, too much of a performance hit + IF ST_NumGeometries(NEW.geometry) > 2000 THEN + RAISE WARNING 'Dropping update of % % because of geometry complexity.', NEW.osm_type, NEW.osm_id; + RETURN NULL; + END IF; + IF coalesce(existing.name::text, '') != coalesce(NEW.name::text, '') OR coalesce(existing.extratags::text, '') != coalesce(NEW.extratags::text, '') OR coalesce(existing.housenumber, '') != coalesce(NEW.housenumber, '')