X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/199308ca5e7719c8adf963e96a8e628334b2a6ab..20f1939c4c61ef28b128593b2ae5f841af567042:/sql/functions.sql diff --git a/sql/functions.sql b/sql/functions.sql index 2ba1b6fa..035eaf90 100644 --- a/sql/functions.sql +++ b/sql/functions.sql @@ -1068,6 +1068,9 @@ BEGIN ELSEIF NEW.class = 'landuse' AND ST_GeometryType(NEW.geometry) in ('ST_Polygon','ST_MultiPolygon') THEN NEW.rank_search := 22; NEW.rank_address := NEW.rank_search; + ELSEIF NEW.class = 'natural' and NEW.type in ('peak','volcano','mountain_range') THEN + NEW.rank_search := 18; + NEW.rank_address := 0; -- any feature more than 5 square miles is probably worth indexing ELSEIF ST_GeometryType(NEW.geometry) in ('ST_Polygon','ST_MultiPolygon') AND ST_Area(NEW.geometry) > 0.1 THEN NEW.rank_search := 22; @@ -1093,9 +1096,6 @@ BEGIN NEW.rank_address := NEW.rank_search; ELSEIF NEW.class = 'natural' and NEW.type in ('coastline') THEN RETURN NULL; - ELSEIF NEW.class = 'natural' and NEW.type in ('peak','volcano') THEN - NEW.rank_search := 18; - NEW.rank_address := 0; END IF; END IF;