Returns the number of points defining the linestring.
SELECT TREAT( Shape AS ST_LineString ).ST_NumPoints() FROM SpatialShapes WHERE ShapeID = 5
SQL/MM (ISO/IEC 13249-3: 2006) 7.2.4