]> git.openstreetmap.org Git - nominatim.git/commitdiff
Merge branch 'master' of http://github.com/twain47/Nominatim
authorSarah Hoffmann <lonvia@denofr.de>
Sun, 19 Aug 2012 21:53:19 +0000 (23:53 +0200)
committerSarah Hoffmann <lonvia@denofr.de>
Sun, 19 Aug 2012 21:53:19 +0000 (23:53 +0200)
data/gb_postcode.sql
sql/functions.sql

index 119574d56431f03662d9fad374625c8ce176b59e..487de9d558c39498335bf3552cda8e778d0a2611 100644 (file)
@@ -1696067,3 +1696067,4 @@ COPY gb_postcode (id, postcode, geometry) FROM stdin;
 -- PostgreSQL database dump complete
 --
 
+GRANT SELECT ON TABLE gb_postcode TO "www-data";
index 548362ad21230775dc9d0bd889cfa416d39649ec..382cb003425816e5e1e75ea43859b507fe1c3a7b 100644 (file)
@@ -2178,7 +2178,7 @@ BEGIN
 
   FOR location IN select * from get_addressdata(for_place_id) where isaddress order by rank_address desc LOOP
     currresult := trim(get_name_by_language(location.name, languagepref));
-    IF currresult != prevresult AND currresult IS NOT NULL THEN
+    IF currresult != prevresult AND currresult IS NOT NULL AND result[(100 - location.rank_address)] IS NULL THEN
       result[(100 - location.rank_address)] := trim(get_name_by_language(location.name, languagepref));
       prevresult := currresult;
     END IF;