Топ-100
 

ST_NUMPOINTS

База данных: MySQL
Текст

ST_NumPoints(ls)

Returns the number of Point objects in the LineString value ls.

ST_NumPoints() handles its arguments as described in the introduction
to this section.

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

Пример

mysql> SET @ls = 'LineString(1 1,2 2,3 3)';
mysql> SELECT ST_NumPoints(ST_GeomFromText(@ls));
+------------------------------------+
| ST_NumPoints(ST_GeomFromText(@ls)) |
+------------------------------------+
| 3 |
+------------------------------------+