Replaces the first z-value of geom by startZ and the last
z-value of geom by endZ, and optionally interpolates
intermediate coordinates relative to segment length according to the
value of interpolate:
Value
Meaning
TRUE (default)
Interpolate intermediate coordinates
FALSE
Update only the first and last z-values
Returns NULL if geom is not a LINESTRING or a
MULTILINESTRING.