Quantcast
Channel: SQL Server Spatial forum
Viewing all articles
Browse latest Browse all 364

Is there any way to get the middle point of a line in T-SQL?

$
0
0

Hi guys, I have a problem with getting the middle point of a line by distance. Example I have a linestring with only 2 coordinates start and end. Let it be 6,7km long, the middle of it is 3,35km far from the start or the end point. So I need the coordinates of that middle point even if that point is not in the original linestring.

I was searching on the forum over days since I started to work with spatial datas and found a bunch of amazing information about everything, but none of them was good solution for this problem.

Just for fun fact, I have about 80.000 linestring which are built up by 2 or more points /and I will have way much more later/, so I'm looking for a solution which is good for both type of linestring regardless of the shape.



Viewing all articles
Browse latest Browse all 364

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>