Citar y Licencia: https://doi.org/10.6084/m9.figshare.27601449.v2
VÃdeo: https://youtu.be/57Y0_HBtCwA
| Grupo | Funciones |
|---|---|
| Relaciones espaciales | ST_Contains, ST_Disjoint,
ST_Equals, ST_Intersects,
ST_Overlaps, ST_Touches,
ST_Within |
| Proximidad y medición | - ST_Buffer, ST_Distance- ST_Area, ST_Length,
ST_Perimeter |
| Transformaciones | - ST_AsBinary, ST_AsText- ST_Difference, ST_Intersection,
ST_Union- ST_Centroid,
ST_ConvexHull, ST_Envelope |
| Operaciones adicionales (no OGC) | ST_AsGeoJSON, ST_Simplify,
ST_Transform |
CREATE TABLE poligonos (
id SERIAL PRIMARY KEY,
geom GEOMETRY(POLYGON, 4326)
);
INSERT INTO poligonos (geom) VALUES
(ST_GeomFromText('POLYGON((0 0, 0 4, 4 4, 4 0, 0 0))', 4326)),
(ST_GeomFromText('POLYGON((1 1, 1 3, 3 3, 3 1, 1 1))', 4326)),
(ST_GeomFromText('POLYGON((3 3, 3 5, 5 5, 5 3, 3 3))', 4326)),
(ST_GeomFromText('POLYGON((4 0, 4 1, 5 1, 5 0, 4 0))', 4326));
SELECT *
FROM
(SELECT DISTINCT ON
(r.contains, r.disjoint, r.equals, r.intersects, r.overlaps, r.touches, r.within)
r.id1, r.id2, r.contains, r.disjoint, r.equals, r.intersects, r.overlaps, r.touches, r.within
FROM
(SELECT a.id AS id1, b.id AS id2,
ST_Contains(a.geom, b.geom) AS contains,
ST_Disjoint(a.geom, b.geom) AS disjoint,
ST_Equals(a.geom, b.geom) AS equals,
ST_Intersects(a.geom, b.geom) AS intersects,
ST_Overlaps(a.geom, b.geom) AS overlaps,
ST_Touches(a.geom, b.geom) AS touches,
ST_Within(a.geom, b.geom) AS within
FROM poligonos a, poligonos b
) AS r
ORDER BY r.contains, r.disjoint, r.equals, r.intersects, r.overlaps, r.touches, r.within,
r.id1, r.id2
) AS q
ORDER BY id1, id2;| id1 | id2 | contains | disjoint | equals | intersects | overlaps | touches | within |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | True | False | True | True | False | False | True |
| 1 | 2 | True | False | False | True | False | False | False |
| 1 | 3 | False | False | False | True | True | False | False |
| 1 | 4 | False | False | False | True | False | True | False |
| 2 | 1 | False | False | False | True | False | False | True |
| 2 | 4 | False | True | False | False | False | False | False |
ST_ContainsSELECT a.id AS id1, b.id AS id2
FROM poligonos a JOIN poligonos b ON ST_Contains(a.geom, b.geom)
WHERE a.id <> b.id;| id1 | id2 |
|---|---|
| 1 | 2 |
ST_DisjointSELECT a.id AS id1, b.id AS id2
FROM poligonos a JOIN poligonos b ON ST_Disjoint(a.geom, b.geom)
WHERE a.id < b.id;| id1 | id2 |
|---|---|
| 2 | 4 |
| 3 | 4 |
ST_EqualsSELECT a.id AS id1, b.id AS id2
FROM poligonos a JOIN poligonos b ON ST_Equals(a.geom, b.geom)
WHERE a.id <= b.id;| id1 | id2 |
|---|---|
| 1 | 1 |
| 2 | 2 |
| 3 | 3 |
| 4 | 4 |
ST_IntersectsSELECT a.id AS id1, b.id AS id2
FROM poligonos a JOIN poligonos b ON ST_Intersects(a.geom, b.geom)
WHERE a.id < b.id;| id1 | id2 |
|---|---|
| 1 | 2 |
| 1 | 3 |
| 1 | 4 |
| 2 | 3 |
ST_OverlapsSELECT a.id AS id1, b.id AS id2
FROM poligonos a JOIN poligonos b ON ST_Overlaps(a.geom, b.geom)
WHERE a.id < b.id;| id1 | id2 |
|---|---|
| 1 | 3 |
ST_TouchesSELECT a.id AS id1, b.id AS id2
FROM poligonos a JOIN poligonos b ON ST_Touches(a.geom, b.geom)
WHERE a.id < b.id;| id1 | id2 |
|---|---|
| 1 | 4 |
| 2 | 3 |
ST_WithinSELECT a.id AS id1, b.id AS id2
FROM poligonos a JOIN poligonos b ON ST_Within(a.geom, b.geom)
WHERE a.id <> b.id;| id1 | id2 |
|---|---|
| 2 | 1 |
CREATE TABLE lineas (
id SERIAL PRIMARY KEY,
geom GEOMETRY(LINESTRING, 4326)
);
INSERT INTO lineas (geom) VALUES
(ST_GeomFromText('LINESTRING(2 -1, 2 5)', 4326)),
(ST_GeomFromText('LINESTRING(0 -1, 3 -1)', 4326)),
(ST_GeomFromText('LINESTRING(-1 4, 5 4)', 4326)),
(ST_GeomFromText('LINESTRING(2 0.5, 2 3.5)', 4326)),
(ST_GeomFromText('LINESTRING(2.5 -1, 5 -1)', 4326));
SELECT *
FROM
(SELECT DISTINCT ON
(r.contains, r.disjoint, r.equals, r.intersects, r.overlaps, r.touches, r.within)
r.id1, r.id2, r.contains, r.disjoint, r.equals, r.intersects, r.overlaps, r.touches, r.within
FROM
(SELECT a.id AS id1, b.id AS id2,
ST_Contains(a.geom, b.geom) AS contains,
ST_Disjoint(a.geom, b.geom) AS disjoint,
ST_Equals(a.geom, b.geom) AS equals,
ST_Intersects(a.geom, b.geom) AS intersects,
ST_Overlaps(a.geom, b.geom) AS overlaps,
ST_Touches(a.geom, b.geom) AS touches,
ST_Within(a.geom, b.geom) AS within
FROM lineas a, lineas b
) AS r
ORDER BY r.contains, r.disjoint, r.equals, r.intersects, r.overlaps, r.touches, r.within,
r.id1, r.id2
) AS q
ORDER BY id1, id2;| id1 | id2 | contains | disjoint | equals | intersects | overlaps | touches | within |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | True | False | True | True | False | False | True |
| 1 | 2 | False | False | False | True | False | True | False |
| 1 | 3 | False | False | False | True | False | False | False |
| 1 | 4 | True | False | False | True | False | False | False |
| 1 | 5 | False | True | False | False | False | False | False |
| 2 | 5 | False | False | False | True | True | False | False |
| 4 | 1 | False | False | False | True | False | False | True |
ST_ContainsSELECT a.id AS id1, b.id AS id2
FROM lineas a JOIN lineas b ON ST_Contains(a.geom, b.geom)
WHERE a.id <> b.id;| id1 | id2 |
|---|---|
| 1 | 4 |
ST_DisjointSELECT a.id AS id1, b.id AS id2
FROM lineas a JOIN lineas b ON ST_Disjoint(a.geom, b.geom)
WHERE a.id < b.id;| id1 | id2 |
|---|---|
| 1 | 5 |
| 2 | 3 |
| 2 | 4 |
| 3 | 4 |
| 3 | 5 |
| 4 | 5 |
ST_EqualsSELECT a.id AS id1, b.id AS id2
FROM lineas a JOIN lineas b ON ST_Equals(a.geom, b.geom)
WHERE a.id <= b.id;| id1 | id2 |
|---|---|
| 1 | 1 |
| 2 | 2 |
| 3 | 3 |
| 4 | 4 |
| 5 | 5 |
ST_IntersectsSELECT a.id AS id1, b.id AS id2
FROM lineas a JOIN lineas b ON ST_Intersects(a.geom, b.geom)
WHERE a.id < b.id;| id1 | id2 |
|---|---|
| 1 | 2 |
| 1 | 3 |
| 1 | 4 |
| 2 | 5 |
ST_OverlapsSELECT a.id AS id1, b.id AS id2
FROM lineas a JOIN lineas b ON ST_Overlaps(a.geom, b.geom)
WHERE a.id < b.id;| id1 | id2 |
|---|---|
| 2 | 5 |
ST_TouchesSELECT a.id AS id1, b.id AS id2
FROM lineas a JOIN lineas b ON ST_Touches(a.geom, b.geom)
WHERE a.id < b.id;| id1 | id2 |
|---|---|
| 1 | 2 |
ST_WithinSELECT a.id AS id1, b.id AS id2
FROM lineas a JOIN lineas b ON ST_Within(a.geom, b.geom)
WHERE a.id <> b.id;| id1 | id2 |
|---|---|
| 4 | 1 |
CREATE TABLE puntos (
id SERIAL PRIMARY KEY,
geom GEOMETRY(POINT, 4326)
);
INSERT INTO puntos (geom) VALUES
(ST_GeomFromText('POINT(2 0)', 4326)),
(ST_GeomFromText('POINT(4 0)', 4326)),
(ST_GeomFromText('POINT(3 -1)', 4326)),
(ST_GeomFromText('POINT(2.5 1.5)', 4326));
SELECT *
FROM
(SELECT DISTINCT ON
(r.contains, r.disjoint, r.equals, r.intersects, r.overlaps, r.touches, r.within)
r.id1, r.id2, r.contains, r.disjoint, r.equals, r.intersects, r.overlaps, r.touches, r.within
FROM
(SELECT a.id AS id1, b.id AS id2,
ST_Contains(a.geom, b.geom) AS contains,
ST_Disjoint(a.geom, b.geom) AS disjoint,
ST_Equals(a.geom, b.geom) AS equals,
ST_Intersects(a.geom, b.geom) AS intersects,
ST_Overlaps(a.geom, b.geom) AS overlaps,
ST_Touches(a.geom, b.geom) AS touches,
ST_Within(a.geom, b.geom) AS within
FROM puntos a, puntos b
) AS r
ORDER BY r.contains, r.disjoint, r.equals, r.intersects, r.overlaps, r.touches, r.within,
r.id1, r.id2
) AS q
ORDER BY id1, id2;| id1 | id2 | contains | disjoint | equals | intersects | overlaps | touches | within |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | True | False | True | True | False | False | True |
| 1 | 2 | False | True | False | False | False | False | False |
ST_DisjointSELECT a.id AS id1, b.id AS id2
FROM puntos a JOIN puntos b ON ST_Disjoint(a.geom, b.geom)
WHERE a.id < b.id;| id1 | id2 |
|---|---|
| 1 | 2 |
| 1 | 3 |
| 1 | 4 |
| 2 | 3 |
| 2 | 4 |
| 3 | 4 |
ST_EqualsSELECT a.id AS id1, b.id AS id2
FROM puntos a JOIN puntos b ON ST_Equals(a.geom, b.geom)
WHERE a.id <= b.id;| id1 | id2 |
|---|---|
| 1 | 1 |
| 2 | 2 |
| 3 | 3 |
| 4 | 4 |
| id1 | id2 | contains | disjoint | equals | intersects | overlaps | touches | within |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | False | False | False | True | False | False | False |
| 1 | 2 | False | True | False | False | False | False | False |
| 1 | 3 | False | False | False | True | False | True | False |
| 1 | 4 | True | False | False | True | False | False | False |
| id1 | id2 | contains | disjoint | equals | intersects | overlaps | touches | within |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | False | False | False | True | False | False | False |
| 1 | 3 | False | True | False | False | False | False | False |
| 3 | 1 | False | False | False | True | False | True | False |
| 4 | 1 | False | False | False | True | False | False | True |
| id1 | id2 | contains | disjoint | equals | intersects | overlaps | touches | within |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | False | False | False | True | False | True | False |
| 1 | 3 | False | True | False | False | False | False | False |
| 1 | 4 | True | False | False | True | False | False | False |
| id1 | id2 | contains | disjoint | equals | intersects | overlaps | touches | within |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | False | False | False | True | False | True | False |
| 1 | 2 | False | True | False | False | False | False | False |
| 4 | 1 | False | False | False | True | False | False | True |
| id1 | id2 | contains | disjoint | equals | intersects | overlaps | touches | within |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | True | False | False | True | False | False | False |
| 1 | 2 | False | True | False | False | False | False | False |
| 2 | 3 | False | False | False | True | False | True | False |
| id1 | id2 | contains | disjoint | equals | intersects | overlaps | touches | within |
|---|---|---|---|---|---|---|---|---|
| 1 | 1 | False | False | False | True | False | False | True |
| 1 | 2 | False | True | False | False | False | False | False |
| 3 | 2 | False | False | False | True | False | True | False |
| Grupo | Funciones |
|---|---|
| Relaciones espaciales | ST_Contains, ST_Disjoint,
ST_Equals, ST_Intersects,
ST_Overlaps, ST_Touches,
ST_Within |
| Proximidad y medición | - ST_Buffer, ST_Distance
- ST_Area, ST_Length,
ST_Perimeter |
| Transformaciones | - ST_AsBinary, ST_AsText- ST_Difference, ST_Intersection,
ST_Union- ST_Centroid,
ST_ConvexHull, ST_Envelope |
| Operaciones adicionales (no OGC) | ST_AsGeoJSON, ST_Simplify,
ST_Transform |
ST_Buffer: obtenciónSELECT 'Punto' AS tipo,
id,
ST_Buffer(ST_Transform(geom, 3857), 100000) AS geom
FROM puntos
WHERE id = 1
UNION ALL
SELECT 'LÃnea' AS tipo,
id,
ST_Buffer(ST_Transform(geom, 3857), 50000) AS geom
FROM lineas
WHERE id = 3
UNION ALL
SELECT 'PolÃgono' AS tipo,
id,
ST_Buffer(ST_Transform(geom, 3857), -20000) AS geom
FROM poligonos
WHERE id = 2;ST_Buffer: resultadoST_Distance: objetosST_Distance: obtenciónSELECT *
FROM
(SELECT
'pu.lÃ' AS tipo,
p.id AS id1,
l.id AS id2,
ST_Distance(ST_Transform(p.geom, 3857),
ST_Transform(l.geom, 3857)) AS distancia_m
FROM
puntos p,
lineas l
UNION ALL
SELECT
'pu.po' AS tipo,
p.id AS id1,
pol.id AS id2,
ST_Distance(ST_Transform(p.geom, 3857),
ST_Transform(pol.geom, 3857)) AS distancia_m
FROM
puntos p,
poligonos pol
UNION ALL
SELECT
'lÃ.po' AS tipo,
l.id AS id1,
pol.id AS id2,
ST_Distance(ST_Transform(l.geom, 3857),
ST_Transform(pol.geom, 3857)) AS distancia_m
FROM
lineas l,
poligonos pol
UNION ALL
SELECT
'pu.pu' AS tipo,
p1.id AS id1,
p2.id AS id2,
ST_Distance(ST_Transform(p1.geom, 3857),
ST_Transform(p2.geom, 3857)) AS distancia_m
FROM
puntos p1,
puntos p2
WHERE
p1.id < p2.id
UNION ALL
SELECT
'lÃ.lÃ' AS tipo,
l1.id AS id1,
l2.id AS id2,
ST_Distance(ST_Transform(l1.geom, 3857),
ST_Transform(l2.geom, 3857)) AS distancia_m
FROM
lineas l1,
lineas l2
WHERE
l1.id < l2.id
UNION ALL
SELECT
'po.po' AS tipo,
pol1.id AS id1,
pol2.id AS id2,
ST_Distance(ST_Transform(pol1.geom, 3857),
ST_Transform(pol2.geom, 3857)) AS distancia_m
FROM
poligonos pol1,
poligonos pol2
WHERE
pol1.id < pol2.id)
WHERE distancia_m > 0
ORDER BY tipo DESC, id1, id2;ST_Distance: resultado| tipo | id1 | id2 | distancia_m |
|---|---|---|---|
| pu.pu | 1 | 2 | 222638.98 |
| pu.pu | 1 | 3 | 157433.53 |
| pu.pu | 1 | 4 | 176029.67 |
| pu.pu | 2 | 3 | 157433.53 |
| pu.pu | 2 | 4 | 236157.79 |
| pu.pu | 3 | 4 | 283834.38 |
| pu.po | 1 | 2 | 111325.14 |
| pu.po | 1 | 3 | 352168.01 |
| pu.po | 1 | 4 | 222638.98 |
| pu.po | 2 | 2 | 157433.53 |
| pu.po | 2 | 3 | 334111.17 |
| pu.po | 3 | 1 | 111325.14 |
| pu.po | 3 | 2 | 222650.29 |
| pu.po | 3 | 3 | 445436.31 |
| pu.po | 3 | 4 | 157433.53 |
| pu.po | 4 | 3 | 176138.34 |
| pu.po | 4 | 4 | 176015.82 |
| pu.là | 1 | 2 | 111325.14 |
| pu.là | 1 | 3 | 445640.11 |
| tipo | id1 | id2 | distancia_m |
|---|---|---|---|
| pu.là | 1 | 4 | 55660.45 |
| pu.là | 1 | 5 | 124464.03 |
| pu.là | 2 | 1 | 222638.98 |
| pu.là | 2 | 2 | 157433.53 |
| pu.là | 2 | 3 | 445640.11 |
| pu.là | 2 | 4 | 229491.18 |
| pu.là | 2 | 5 | 111325.14 |
| pu.là | 3 | 1 | 111319.49 |
| pu.là | 3 | 3 | 556965.25 |
| pu.là | 3 | 4 | 200689.36 |
| pu.là | 4 | 1 | 55659.75 |
| pu.là | 4 | 2 | 278323.46 |
| pu.là | 4 | 3 | 278641.80 |
| pu.là | 4 | 4 | 55659.75 |
| pu.là | 4 | 5 | 278323.46 |
| po.po | 2 | 4 | 111319.49 |
| po.po | 3 | 4 | 222786.03 |
| lÃ.po | 1 | 3 | 111319.49 |
| lÃ.po | 1 | 4 | 222638.98 |
| tipo | id1 | id2 | distancia_m |
|---|---|---|---|
| lÃ.po | 2 | 1 | 111325.14 |
| lÃ.po | 2 | 2 | 222650.29 |
| lÃ.po | 2 | 3 | 445436.31 |
| lÃ.po | 2 | 4 | 157433.53 |
| lÃ.po | 3 | 2 | 111528.94 |
| lÃ.po | 3 | 4 | 334314.97 |
| lÃ.po | 4 | 3 | 111319.49 |
| lÃ.po | 4 | 4 | 222638.98 |
| lÃ.po | 5 | 1 | 111325.14 |
| lÃ.po | 5 | 2 | 222650.29 |
| lÃ.po | 5 | 3 | 445436.31 |
| lÃ.po | 5 | 4 | 111325.14 |
| lÃ.là | 1 | 5 | 55659.75 |
| lÃ.là | 2 | 3 | 556965.25 |
| lÃ.là | 2 | 4 | 166985.59 |
| lÃ.là | 3 | 4 | 55779.35 |
| lÃ.là | 3 | 5 | 556965.25 |
| lÃ.là | 4 | 5 | 176017.60 |
ST_Area, ST_Length, ST_Perimeter:
obtenciónSELECT *
FROM
(SELECT
'Punto' AS geometria,
p.id,
ST_Area(ST_Transform(p.geom, 3857)) AS area_m2,
ST_Length(ST_Transform(p.geom, 3857)) AS length_m,
ST_Perimeter(ST_Transform(p.geom, 3857)) AS perimeter_m
FROM
puntos p
UNION ALL
SELECT
'LÃnea' AS geometria,
l.id,
ST_Area(ST_Transform(l.geom, 3857)) AS area_m2,
ST_Length(ST_Transform(l.geom, 3857)) AS length_m,
ST_Perimeter(ST_Transform(l.geom, 3857)) AS perimeter_m
FROM
lineas l
UNION ALL
SELECT
'PolÃgono' AS geometria,
pol.id,
ST_Area(ST_Transform(pol.geom, 3857)) AS area_m2,
ST_Length(ST_Transform(pol.geom, 3857)) AS length_m,
ST_Perimeter(ST_Transform(pol.geom, 3857)) AS perimeter_m
FROM
poligonos pol)
ORDER BY geometria, id;ST_Area, ST_Length, ST_Perimeter:
resultado| geometria | id | area_m2 | length_m | perimeter_m |
|---|---|---|---|---|
| LÃnea | 1 | 0 | 668630.4 | 0.0 |
| LÃnea | 2 | 0 | 333958.5 | 0.0 |
| LÃnea | 3 | 0 | 667916.9 | 0.0 |
| LÃnea | 4 | 0 | 334200.3 | 0.0 |
| LÃnea | 5 | 0 | 278298.7 | 0.0 |
| PolÃgono | 1 | 198433720336 | 0.0 | 1781836.1 |
| PolÃgono | 2 | 49600854505 | 0.0 | 890850.0 |
| PolÃgono | 3 | 49691703975 | 0.0 | 891666.1 |
| PolÃgono | 4 | 12392658216 | 0.0 | 445289.3 |
| Punto | 1 | 0 | 0.0 | 0.0 |
| Punto | 2 | 0 | 0.0 | 0.0 |
| Punto | 3 | 0 | 0.0 | 0.0 |
| Punto | 4 | 0 | 0.0 | 0.0 |
| Grupo | Funciones |
|---|---|
| Relaciones espaciales | ST_Contains, ST_Disjoint,
ST_Equals, ST_Intersects,
ST_Overlaps, ST_Touches,
ST_Within |
| Proximidad y medición | - ST_Buffer, ST_Distance - ST_Area, ST_Length,
ST_Perimeter |
| Transformaciones | - ST_AsBinary, ST_AsText- ST_Difference, ST_Intersection,
ST_Union- ST_Centroid,
ST_ConvexHull, ST_Envelope |
| Operaciones adicionales (no OGC) | ST_AsGeoJSON, ST_Simplify,
ST_Transform |
ST_Difference: polÃgono y polÃgonoST_Difference: lÃnea y lÃnea| id | geom |
|---|---|
| 1 | MULTILINESTRING((2 -1,2 0.5),(2 3.5,2 5)) |
ST_Difference: lÃneas y polÃgono| id | geom |
|---|---|
| 1 | MULTILINESTRING((2 -1,2 0),(2 4,2 5)) |
| 2 | LINESTRING(0 -1,3 -1) |
| 3 | MULTILINESTRING((-1 4,0 4),(4 4,5 4)) |
| 4 | LINESTRING EMPTY |
| 5 | LINESTRING(2.5 -1,5 -1) |
ST_Difference: polÃgono y lÃnea (i)ST_Difference: polÃgono y lÃnea (y ii)| id | geom |
|---|---|
| 1 | POLYGON((0 0,0 4,4 4,4 0,0 0)) |
| 1 | POLYGON((0 4,2 4,4 4,4 0,2 0,0 0,0 4)) |
ST_Difference: puntos y polÃgono| id | geom |
|---|---|
| 1 | POINT EMPTY |
| 2 | POINT EMPTY |
| 3 | POINT(3 -1) |
| 4 | POINT EMPTY |
ST_Difference: puntos y lÃnea (i)| id | geom |
|---|---|
| 1 | POINT EMPTY |
| 2 | POINT(4 0) |
| 3 | POINT(3 -1) |
| 4 | POINT(2.5 1.5) |
ST_Difference: puntos y lÃnea (y ii)| id | geom |
|---|---|
| 1 | POINT(2 0) |
| 2 | POINT(4 0) |
| 3 | POINT EMPTY |
| 4 | POINT(2.5 1.5) |
| Grupo | Funciones |
|---|---|
| Relaciones espaciales | ST_Contains, ST_Disjoint,
ST_Equals, ST_Intersects,
ST_Overlaps, ST_Touches,
ST_Within |
| Proximidad y medición | - ST_Buffer, ST_Distance - ST_Area, ST_Length,
ST_Perimeter |
| Transformaciones | - ST_AsBinary, ST_AsText- ST_Difference, ST_Intersection,
ST_Union- ST_Centroid,
ST_ConvexHull, ST_Envelope |
| Operaciones adicionales (no OGC) | ST_AsGeoJSON, ST_Simplify,
ST_Transform |
ST_Centroid: polÃgonos (i)ST_Centroid: polÃgonos (y ii)ST_Centroid: lÃneas (i)ST_Centroid: lÃneas (y ii)ST_Centroid: puntosST_ConvexHull: polÃgonosST_ConvexHull: lÃneasST_ConvexHull: puntosST_Envelope: polÃgonosST_Envelope: lÃneasST_Envelope: puntos| Grupo | Funciones |
|---|---|
| Relaciones espaciales | ST_Contains, ST_Disjoint,
ST_Equals, ST_Intersects,
ST_Overlaps, ST_Touches,
ST_Within |
| Proximidad y medición | - ST_Buffer, ST_Distance - ST_Area, ST_Length,
ST_Perimeter |
| Transformaciones | - ST_AsBinary, ST_AsText- ST_Difference, ST_Intersection,
ST_Union- ST_Centroid,
ST_ConvexHull, ST_Envelope |
| Operaciones adicionales (no OGC) | ST_AsGeoJSON,
ST_Simplify,
ST_Transform |
| Grupo | Funciones |
|---|---|
| Relaciones espaciales | ST_Contains, ST_Disjoint,
ST_Equals, ST_Intersects,
ST_Overlaps, ST_Touches,
ST_Within |
| Proximidad y medición | - ST_Buffer, ST_Distance - ST_Area, ST_Length,
ST_Perimeter |
| Transformaciones | - ST_AsBinary, ST_AsText- ST_Difference, ST_Intersection,
ST_Union- ST_Centroid,
ST_ConvexHull, ST_Envelope |
| Operaciones adicionales (no OGC) | ST_AsGeoJSON, ST_Simplify,
ST_Transform |