ST_ChangePoint function
The ST_ChangePoint function takes a curve and two points as input parameters. It replaces all occurrences of the first point in the given curve with the second point and returns the resulting curve. The resulting geometry is represented in the spatial reference system of the given geometry.
If the two points are not represented in the same spatial reference system as the curve, they will be converted to the spatial reference system used for the curve.
If the given curve is empty, then an empty value is returned. If the given curve is null, or if any of the given points is null or empty, then null is returned.
This function can also be called as a method.
Syntax
Parameter
- curve
- A value of type ST_Curve or one of its subtypes that represents the curve in which the points identified by old_point are changed tonew_point.
- old_point
- A value of type ST_Point that identifies the points in the curve that are changed to new_point.
- new_point
- A value of type ST_Point that represents the new locations of the points in the curve identified by old_point.
Return type
db2gse.ST_Curve
Restrictions
The point to be changed in the curve must be one of the points used to define the curve.
If the curve has Z or M coordinates, then the given points also must have Z or M coordinates.