Hi,

I need to find the intersection point between two lines,
the first choice is ST_Intersection, but I notice even the ST_ClosestPoint function.

Testing both:

select ST_AsText(ST_ClosestPoint(ST_GeomFromEWKT('SRID=3003;LINESTRING(4 4, 6 6)'),ST_GeomFromEWKT('SRID=3003;LINESTRING(12 1, 3 5)')));

--> POINT(4.38461538461539 4.38461538461539)

select ST_AsText(ST_Intersection(ST_GeomFromEWKT('SRID=3003;LINESTRING(4 4, 6 6)'),ST_GeomFromEWKT('SRID=3003;LINESTRING(12 1, 3 5)')));

--> POINT(4.38461538461539 4.38461538461539)

They gave the same result.

Supposing the geometry to check are linestrings
there is some difference between the two functions ?

Thx,

Andrea.

_______________________________________________
postgis-users mailing list
[email protected]
http://postgis.refractions.net/mailman/listinfo/postgis-users

Reply via email to