Returns the area of a 2D polygon.
<geo.area>
<geom_column /> *
</geo.area>
Arguments |
Name | Type | Required | Unique | Nullable | Description |
Egeom_column | geometry | | | | Geometric object of type (MULTI) POLYGON. |
Example
Copy
<select>
<columns>
<geo.area tol='4326' unit='SQ_KM'>a.the_geom</geo.reverseLine>
</columns>
<from table='buildings' alias='a' />
</select>
Calculate the Cartesian distance between two geometric objects.
The distance between two geometric objects is the distance between the closest points or segments between both objects.
<geo.distanceCartesian
ora_tol='ora_tol'
ora_unit='M|KM|CM|MM|MILE|NAUT_MILE|FOOT|INCH|SQ_KM...'
>
<geom1> *
<geom1 /> *
</geom1>
<geom2> *
<geom1 /> *
</geom2>
</geo.distanceCartesian>
Attributes |
Name | Type | Required | Default | Description |
Aora_tol | decimal | | | 0.05 | Tolerance. It is only used in Oracle. |
Aora_unit | string | | | | Unit of measure. If not specified, Oracle will use default unit of geometry SRID. It is only used in Oracle. |
Arguments |
Name | Type | Required | Unique | Nullable | Description |
Egeom1 | geometry | | | | Geometric object 1 |
Egeom1 | geometry | | | | |
Egeom2 | geometry | | | | Geometric object 2 |
Egeom1 | geometry | | | | |
Example
Copy
<select>
<columns>
<geo.distanceCartesian ora_tol='0.004' ora_unit='KM'>
<geom1>a.the_geom</geom1>
<geom2>a.the_geom</geom2>
</geo.distanceCartesian>
</columns>
<from table='points' alias='a' >
<join table='points' alias='b'>
</join>
</from>
<where>
a.id = 134 AND b.id = 24356
</where>
</select>
Returns the linear distance between two lat/long points located on a perfect sphere of radius = 6370986m. It is faster than geo.distanceSpheroid but less accurate.
<geo.distanceSphere
ora_tol='ora_tol'
ora_unit='M|KM|CM|MM|MILE|NAUT_MILE|FOOT|INCH|SQ_KM...'
>
<geom1> *
<geom1 /> *
</geom1>
<geom2> *
<geom1 /> *
</geom2>
</geo.distanceSphere>
Attributes |
Name | Type | Required | Default | Description |
Aora_tol | decimal | | | 0.05 | Tolerance. It is only used in Oracle. |
Aora_unit | string | | | | Unit of measure. If not specified, Oracle will use default unit of geometry SRID. It is only used in Oracle. |
Arguments |
Name | Type | Required | Unique | Nullable | Description |
Egeom1 | geometry | | | | POINT type geometric object |
Egeom1 | geometry | | | | |
Egeom2 | geometry | | | | POINT type geometric object |
Egeom1 | geometry | | | | |
Example
Copy
<select>
<columns>
<geo.distanceSphere ora_tol=''>
<geom1>a.the_geom</geom1>
<geom2>a.the_geom</geom2>
</geo.distanceSphere>
</columns>
<from table='points' alias='a' >
<join table='points' alias='b'>
</join>
</from>
<where>
a.name = 'Barcelona' AND b.name = 'London'
</where>
</select>
Returns the linear distance between two lat/long points located on the indicated spheroid.
<geo.distanceSpheroid
ora_tol='ora_tol'
ora_unit='M|KM|CM|MM|MILE|NAUT_MILE|FOOT|INCH|SQ_KM...'
>
<geom1> *
<geom1 /> *
</geom1>
<geom2> *
<geom1 /> *
</geom2>
<spheroid /> *
</geo.distanceSpheroid>
Attributes |
Name | Type | Required | Default | Description |
Aora_tol | decimal | | | 0.05 | Tolerance. It is only used in Oracle. |
Aora_unit | string | | | | Unit of measure. If not specified, Oracle will use the default unit of the geometry SRID. It is only used in Oracle. |
Arguments |
Name | Type | Required | Unique | Nullable | Description |
Egeom1 | geometry | | | | POINT type geometric object |
Egeom1 | geometry | | | | |
Egeom2 | geometry | | | | POINT type geometric object |
Egeom1 | geometry | | | | |
Espheroid | geometry | | | | Definition of the spheroid on which the distance is calculated. |
Example
Copy
<select>
<columns>
<geo.distanceSpheroid ora_tol='0.005'>
<geom1>a.the_geom</geom1>
<geom2>a.the_geom</geom2>
<spheroid> 'SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]]'</spheroid>
</geo.distanceSpheroid>
</columns>
<from table='points' alias='a' >
<join table='points' alias='b'>
</join>
</from>
<where>
a.name = 'Barcelona' AND b.name = 'London'
</where>
</select>
Returns the linear distance between two lat/long points located on the indicated spheroid.
<geo.length
ora_tol='ora_tol'
ora_unit='M|KM|CM|MM|MILE|NAUT_MILE|FOOT|INCH|SQ_KM...'
>
<geometry_column /> *
</geo.length>
Attributes |
Name | Type | Required | Default | Description |
Aora_tol | decimal | | | 0.05 | Tolerancia. Solo se utiliza en oracle. |
Aora_unit | string | | | | Unit of measure. If not specified, Oracle will use the default unit of the geometry SRID. It is only used in Oracle. |
Arguments |
Name | Type | Required | Unique | Nullable | Description |
Egeometry_column | geometry | | | | POINT type geometric object. |
Example
Copy
<select>
<columns>
<geo.length ora_tol='0.005'>a.the_geom</geo.length>
</columns>
<from table='roads' alias='a' />
<where>
a.name = 'A-7'
</where>
</select>
Returns the length of a line on the indicated spheroid.
<geo.lengthSpheroid
ora_tol='ora_tol'
ora_unit='M|KM|CM|MM|MILE|NAUT_MILE|FOOT|INCH|SQ_KM...'
>
<geom1> *
<geom1 /> *
</geom1>
<geom2> *
<geom1 /> *
</geom2>
<spheroid /> *
</geo.lengthSpheroid>
Attributes |
Name | Type | Required | Default | Description |
Aora_tol | decimal | | | 0.05 | Tolerance. It is only used in Oracle. |
Aora_unit | string | | | | Unit of measure. If not specified, ORACLE will use the default unit of the geometry SRID. It is only used in Oracle. |
Arguments |
Name | Type | Required | Unique | Nullable | Description |
Egeom1 | geometry | | | | POINT type geometric object. |
Egeom1 | geometry | | | | |
Egeom2 | geometry | | | | POINT type geometric object. |
Egeom1 | geometry | | | | |
Espheroid | text | | | | Definition of the spheroid on which the length is calculated. |
Example
Copy
<select>
<columns>
<geo.lengthSpheroid ora_tol='0.005'>
<geom1>a.the_geom</geom1>
<spheroid> 'SPHEROID["WGS 84",6378137,298.257223563,AUTHORITY["EPSG","7030"]]'</spheroid>
</geo.distanceSpheroid>
</columns>
<from table='points' alias='a' >
<join table='points' alias='b'>
</join>
</from>
<where>
a.name = 'Barcelona' AND b.name = 'London'
</where>
</select>
Returns the perimeter of the geometric object of the argument received by function (geometric column).
<geo.perimeter
pg_dim='2|3'
ora_tol='ora_tol'
ora_unit='M|KM|CM|MM|MILE|NAUT_MILE|FOOT|INCH|SQ_KM...'
>
<geometry_column /> *
</geo.perimeter>
Attributes |
Name | Type | Required | Default | Description |
Apg_dim | integer | | | | Number of dimensions of the geometric object. It is only used in Postgres. By default it is 2. |
Aora_tol | decimal | | | 0.05 | Tolerance. Only used in Oracle. |
Aora_unit | string | | | | Unit of measure. If not specified, Oracle will use the default unit of the geometry SRID. It is only used in Oracle. |
Arguments |
Name | Type | Required | Unique | Nullable | Description |
Egeometry_column | geometry | | | | Geometric object. |
Example
Copy
<select>
<columns>
<geo.perimeter ora_tol='0.005' pg_dim='3' ora_unit='3'>a.the_geom</geo.perimeter>
</columns>
<from table='buildings' alias='a' />
<where>
a.name = 'MACBA'
</where>
</select>
Returns the geometric center of a geometry or a set of geometries.
The geometry must be one or a set of POINTS, POLYGON or MULTIPOLYGON.
<geo.centroid ora_tol='ora_tol'>
<geometry_column /> *
</geo.centroid>
Attributes |
Name | Type | Required | Default | Description |
Aora_tol | decimal | | | 0.05 | Tolerance. It is only used in Oracle. |
Arguments |
Name | Type | Required | Unique | Nullable | Description |
Egeometry_column | geometry | | | | Geometric object. |
Example
Copy
<select>
<columns>
<geo.centroid ora_tol='0.005'>a.the_geom</geo.centroid>
</columns>
<from table='buildings' alias='a' />
<where>
a.name = 'MACBA'
</where>
</select>
Returns the geometric center of a geometry or set of geometries.
The geometry must be one or a set of POINTS, POLYGON or MULTIPOLYGON.
<geo.withinDist
ora_operator='y'
ora_tol='ora_tol'
ora_unit='M|KM|CM|MM|MILE|NAUT_MILE|FOOT|INCH|SQ_KM...'
>
<geom1> *
<geom1 /> *
</geom1>
<geom2> *
<geom1 /> *
</geom2>
<spheroid /> *
</geo.withinDist>
Attributes |
Name | Type | Required | Default | Description |
Aora_operator | string | | | | Tolerance. Only used in Oracle. |
Aora_tol | decimal | | | 0.05 | Tolerance. Only used in Oracle. |
Aora_unit | string | | | | Unit of measure. If not specified, Oracle will use the default unit of the geometry SRID. It is only used in Oracle. |
Arguments |
Name | Type | Required | Unique | Nullable | Description |
Egeom1 | geometry | | | | POINT type geometric object. |
Egeom1 | geometry | | | | |
Egeom2 | geometry | | | | POINT type geometric object. |
Egeom1 | geometry | | | | |
Espheroid | text | | | | Definition of the spheroid on which the length is calculated. |
Example
Copy
<select>
<columns>
<geo.withinDist ora_unit='KM' ora_tol='' ora_operator='y'>
<geom1>geometry_col_1</geom1>
<geom2>geometry_col_2</geom2>
<dist>10</dist>
</geo.withinDist>
</columns>
<from table='buildings' alias='a' />
<where>
a.name = 'MACBA'
</where>
</select>