Nota
El acceso a esta página requiere autorización. Puede intentar iniciar sesión o cambiar directorios.
El acceso a esta página requiere autorización. Puede intentar cambiar los directorios.
适用于: Databricks Runtime 17.1 及更高版本
重要
此功能目前以公共预览版提供。
交换输入几何图形的 X 和 Y 坐标。
语法
st_flipcoordinates ( geoExpr )
论据
-
geoExpr
:一个GEOMETRY
值。
退货
一个交换了 X 和 Y 坐标的 GEOMETRY
类型的值。
输出 GEOMETRY
值的 SRID 值等于输入值的 SRID 值。
如果输入为 NULL
.,则函数返回 NULL
。
例子
-- Swaps X and Y coordinates of a linestring.
> SELECT st_astext(st_flipcoordinates(st_geomfromtext('LINESTRING(1 2,3 4,5 6,7 8)')));
LINESTRING(2 1,4 3,6 5,8 7)
-- Swaps X and Y coordinates of a point.
> SELECT st_astext(st_flipcoordinates(st_geomfromtext('POINT(10 20)')));
POINT(20 10)