Line_Interpolate_Point
LINE_INTERPOLATE_POINT(g Geometry, f float);
Alias: ST_LINE_INTERPOLATE_POINT
Interpolates a point from the line given using the float as a fraction of where on the line this point will lie.
The first argument 'g' must be of type Linestring, LinestringZ, LinestringM, or LinestringZM.
The second argument 'f' must be a float with a value between 0 and 1.
Result type: point
Example:
SELECT ASTEXT(LINE_INTERPOLATE_POINT(GEOMFROMTEXT('LINESTRING(0 0, 5 5, 10 10)'), 0.5));
-------------
col1
-------------
POINT(5 5)
-------------
SELECT ASTEXT(LINE_INTERPOLATE_POINT(GEOMFROMTEXT('LINESTRING(0 0, 5 5, 10 10)'), 0.75));
-------------
col1
-------------
POINT(7.5 7.5)
-------------
Last modified date: 01/30/2023