Length of a LineString is sought
mysql>
mysql>
mysql> SET @gc = GEOMFROMTEXT('GEOMETRYCOLLECTION(POINT(10 10), POINT(0 100), POINT(40 40), LINESTRING(10 0, 10 10, 20 1
0))');
Query OK, 0 rows affected (0.00 sec)
mysql>
mysql> SELECT GLENGTH(GEOMETRYN(@gc, 4));
+----------------------------+
| GLENGTH(GEOMETRYN(@gc, 4)) |
+----------------------------+
| 20 |
+----------------------------+
1 row in set (0.00 sec)
mysql>
mysql>
Related examples in the same category