]> git.openstreetmap.org Git - nominatim.git/commitdiff
Merge pull request #1971 from lonvia/drop-support-for-isin
authorSarah Hoffmann <lonvia@denofr.de>
Wed, 23 Sep 2020 07:20:35 +0000 (09:20 +0200)
committerGitHub <noreply@github.com>
Wed, 23 Sep 2020 07:20:35 +0000 (09:20 +0200)
Drop support for is_in tag

settings/import-extratags.style
settings/import-full.style
sql/functions/placex_triggers.sql
test/bdd/db/import/search_name.feature

index b90a07b164bb2f53a880ff6934ca91b1af3e9730..63c4a7ae86ba9f8e60d18e14005aec0f320bbfe4 100644 (file)
     }
 },
 {
-    "keys" : ["addr:*", "is_in:*", "tiger:county", "is_in"],
+    "keys" : ["addr:*", "is_in:*", "tiger:county"],
     "values" : {
         "" : "address"
     }
index 8660090173e5a2705f33ef0232a0028816542ec3..6728bd57ee1cd457db640320dc9fb0e373ba41bb 100644 (file)
     }
 },
 {
-    "keys" : ["addr:*", "is_in:*", "tiger:county", "is_in"],
+    "keys" : ["addr:*", "is_in:*", "tiger:county"],
     "values" : {
         "" : "address"
     }
index 0faa80201f4bf5ee6092236f851602e301c99349..2bc7efad826e9ab8461c05a4debd7c0aca8d523d 100644 (file)
@@ -290,23 +290,6 @@ BEGIN
         END IF;
       END IF;
     END LOOP;
-
-    IF address ? 'is_in' THEN
-      -- is_in items need splitting
-      isin := regexp_split_to_array(address->'is_in', E'[;,]');
-      IF array_upper(isin, 1) IS NOT NULL THEN
-        FOR i IN 1..array_upper(isin, 1) LOOP
-          isin_tokens := array_merge(isin_tokens,
-                                     word_ids_from_name(isin[i]));
-
-          -- merge word into address vector
-          IF NOT %REVERSE-ONLY% THEN
-            nameaddress_vector := array_merge(nameaddress_vector,
-                                              addr_ids_from_name(isin[i]));
-          END IF;
-        END LOOP;
-      END IF;
-    END IF;
   END IF;
   IF NOT %REVERSE-ONLY% THEN
     nameaddress_vector := array_merge(nameaddress_vector, isin_tokens);
index 14cf3769a1e43f274cdc00ce81c55c6d2c7a6a5b..3fda7ae8afaf98477d4ab56d377cdbd2ce45ad2b 100644 (file)
@@ -223,21 +223,6 @@ Feature: Creation of search terms
          | object | nameaddress_vector |
          | W1     | 12345 |
 
-    Scenario: is_in is split and added to the address search terms
-        Given the scene roads-with-pois
-        And the places
-         | osm | class   | type        | name     | geometry |
-         | N1  | place   | state       | new york | 80 80 |
-         | N2  | place   | city        | bonn     | 81 81 |
-         | N3  | place   | suburb      | smalltown| 80 81 |
-        And the named places
-         | osm | class   | type    | addr+is_in                | geometry |
-         | W1  | highway | service | bonn, New York, Smalltown | :w-north |
-        When importing
-        Then search_name contains
-         | object | nameaddress_vector |
-         | W1     | bonn, new york, smalltown |
-
     Scenario: a linked place does not show up in search name
         Given the named places
          | osm  | class    | type           | admin | geometry |