X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/c755733b03a1a5c4a1243af09bee5af7f3a226d3..65a1ef1ad120c90b658e034efd54fa173e146671:/sql/postgis_20_aux.sql diff --git a/sql/postgis_20_aux.sql b/sql/postgis_20_aux.sql index dc74e093..749e2a43 100644 --- a/sql/postgis_20_aux.sql +++ b/sql/postgis_20_aux.sql @@ -4,7 +4,7 @@ CREATE OR REPLACE FUNCTION split_line_on_node(line GEOMETRY, point GEOMETRY) RETURNS GEOMETRY AS $$ BEGIN - RETURN ST_Split(line, ST_ClosestPoint(line, point)); + RETURN ST_Split(ST_Snap(line, point, 0.0005), point); END; $$ LANGUAGE plpgsql;