STValidLrsPoint

STValidLrsPoint — Checks if supplied @p_point is a valid LRS point.

Function Specification.

Function STValidLrsPoint (
           @p_point geometry
    )
Returns bit

Description.

Function returns 1 (true) if point is measured, and 0 (false) if point is not measured.

A valid LRS point has measure information.

The function checks for the Point geometry type and has a measured ordinate.

Parameters.

    @p_point (geometry) - Measured Point.

Result.

The function returns 1 (true) if measured point, 0 (false) otherwise.

Example.

select [lrs].[STValidLrsPoint](geometry::STGeomFromText('POINT(0 0)',0)) as is_measured_point
GO

is_measured_point
0

select [lrs].[STValidLrsPoint](geometry::STGeomFromText('POINT(0 0 NULL 1)',0)) as is_measured_point
GO

is_measured_point
1