From: Sarah Hoffmann Date: Thu, 24 May 2012 20:47:34 +0000 (+0200) Subject: remove distinct, causes nearest feature results to be badly reordered X-Git-Tag: v2.0.0~59 X-Git-Url: https://git.openstreetmap.org./nominatim.git/commitdiff_plain/c433a2d739f9456224a83d4b3b3664b49c8d1775 remove distinct, causes nearest feature results to be badly reordered --- diff --git a/sql/functions.sql b/sql/functions.sql index c025f221..554ddf32 100644 --- a/sql/functions.sql +++ b/sql/functions.sql @@ -1630,7 +1630,7 @@ BEGIN location_rank_search := 100; location_distance := 0; -- RAISE WARNING ' getNearFeatures(%,''%'',%,''%'')',NEW.partition, place_centroid, search_maxrank, isin_tokens; - FOR location IN SELECT distinct * from getNearFeatures(NEW.partition, place_centroid, search_maxrank, isin_tokens) LOOP + FOR location IN SELECT * from getNearFeatures(NEW.partition, place_centroid, search_maxrank, isin_tokens) LOOP --RAISE WARNING ' AREA: %',location; @@ -1662,7 +1662,7 @@ BEGIN FOR i IN 1..array_upper(isin_tokens, 1) LOOP --RAISE WARNING ' getNearestNamedFeature: % % % %',NEW.partition, place_centroid, search_maxrank, isin_tokens[i]; - FOR location IN SELECT distinct * from getNearestNamedFeature(NEW.partition, place_centroid, search_maxrank, isin_tokens[i]) LOOP + FOR location IN SELECT * from getNearestNamedFeature(NEW.partition, place_centroid, search_maxrank, isin_tokens[i]) LOOP --RAISE WARNING ' ISIN: %',location;