]> git.openstreetmap.org Git - nominatim.git/commitdiff
restrict max admin_level when patching in tag changes into placex
authorSarah Hoffmann <lonvia@denofr.de>
Thu, 19 Sep 2013 21:42:15 +0000 (23:42 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Thu, 19 Sep 2013 21:42:15 +0000 (23:42 +0200)
sql/functions.sql

index 09ff155c1e26eb3781148f2312906f62255f225f..5bbaad5b0d60b704dfab41331d2d8df292dbb6bc 100644 (file)
@@ -2251,7 +2251,7 @@ BEGIN
       country_code = NEW.country_code,
       parent_place_id = null,
       extratags = NEW.extratags,
-      admin_level = NEW.admin_level,
+      admin_level = CASE WHEN NEW.admin_level > 15 THEN 15 ELSE NEW.admin_level END,
       indexed_status = 2,    
       geometry = NEW.geometry
       where place_id = existingplacex.place_id;