ST_NumPoints(ls)

Returns the number of Point objects in the LineString value ls. If the
argument is NULL or an empty geometry, the return value is NULL.

URL: https://dev.mysql.com/doc/refman/5.7/en/gis-linestring-property-functions.html

