NumGeometries(gc)
            
              Retorna o número de geometrias no valor
              GeometryCollection
              gc.
mysql> SELECT NumGeometries(GeomFromText('GeometryCollection(Point(1 1),LineString(2 2, 3 3))'));
+------------------------------------------------------------------------------------+
| NumGeometries(GeomFromText('GeometryCollection(Point(1 1),LineString(2 2, 3 3))')) |
+------------------------------------------------------------------------------------+
|                                                                                  2 |
+------------------------------------------------------------------------------------+
              GeometryN(gc,n)
            
              Retorna o n-ésima geometria no valor
              GeometryCollection
              gc. O número de geometrias começa em
              1.
mysql> SELECT AsText(GeometryN(GeomFromText('GeometryCollection(Point(1 1),LineString(2 2, 3 3))'),1));
+------------------------------------------------------------------------------------------+
| AsText(GeometryN(GeomFromText('GeometryCollection(Point(1 1),LineString(2 2, 3 3))'),1)) |
+------------------------------------------------------------------------------------------+
| POINT(1 1)                                                                               |
+------------------------------------------------------------------------------------------+
          Nota: Funções para tipos de
          geometrias específicas retornam NULL se a
          geomtria passada é do tipo de geometria errado. Por exemplo
          Area() retorna NULL se o
          tipo do objeto não é nem Polygon nem
          MultiPolygon.
        
This is a translation of the MySQL Reference Manual that can be found at dev.mysql.com. The original Reference Manual is in English, and this translation is not necessarily as up to date as the English version.

