geoGetNum

Function: geoGetNum(Geometry value, Decimal Places)

Returns the number of Geometries in a GeometryCollection or Multipolygon.

If passed a string the geometry functions will automatically convert it into a geometry object.

Syntax

geoGetNum( geometryValue, decimalPlaces

ArgumentTypeDescription
geometryValue

WTK String or

Geometry Object

The geometry to test for number of geometries.
decimalPlacesIntegerThe number of decimal places to use in the geometry calculations. Defaults to 0 if not provided. Can also take negative values e.g. -1 uses geometry to the nearest 10.

Examples

geoGetNum("MULTIPOLYGON (((0 0, 0 2, 2 2, 2 0, 0 0)), ((0 0, 0 -2, -2 -2, -2 0, 0 0)))")

Returns the number of geometries as an Integer


See Also