适用于:
Databricks SQL
Databricks 运行时 17.1 及以上
Lakehouse//RT
Important
此功能目前以公共预览版提供。
注释
此功能在 Databricks SQL 经典仓库上不可用。 若要详细了解 Databricks SQL 仓库,请参阅 SQL 仓库类型。
分析地理的 WKT 说明并返回相应的 GEOGRAPHY 值。
返回 GEOGRAPHY 值的 SRID 值为 4326。
Syntax
st_geogfromtext ( wktExpr )
Arguments
-
wktExpr:一个STRING数值,表示以 WKT 格式表示的地理区域。
Returns
具有GEOGRAPHY(4326)类型的值,对应于输入的WKT描述。
如果输入为 NULL.,则函数返回 NULL 。
错误条件
- 如果
wktExpr的值为无效的 WKT 说明,则函数将返回 WKT_PARSE_ERROR。
Examples
-- Simple example.
> SELECT st_asgeojson(st_geogfromtext('POINT Z (1 2 3)'));
{"type":"Point","coordinates":[1,2,3]}
相关函数
-
st_asbinary函数 -
st_asewkb函数 -
st_asewkt函数 -
st_asgeojson函数 -
st_astext函数 -
st_geogfromewkt函数 -
st_geogfromgeojson函数 -
st_geogfromwkb函数 -
st_geogfromwkt函数 -
st_geomfromewkb函数 -
st_geomfromewkt函数 -
st_geomfromgeojson函数 -
st_geomfromtext函数 -
st_geomfromwkb函数 -
st_geomfromwkt函数 -
to_geography函数 -
to_geometry函数 -
try_to_geography函数 -
try_to_geometry函数