Märkus.
Juurdepääs sellele lehele nõuab autoriseerimist. Võite proovida sisse logida või kausta vahetada.
Juurdepääs sellele lehele nõuab autoriseerimist. Võite proovida kausta vahetada.
Important
This feature is in Public Preview.
Returns the input Geography or Geometry value in WKT format.
For the corresponding Databricks SQL function, see st_astext function.
Syntax
from pyspark.databricks.sql import functions as dbf
dbf.st_astext(col=<col>)
Parameters
| Parameter | Type | Description |
|---|---|---|
col |
pyspark.sql.Column or str |
A geospatial value, either a Geography or Geometry. |
Examples
from pyspark.databricks.sql import functions as dbf
df = spark.createDataFrame([('POINT Z (2.718281 3.141592 100)',)], ['wkt'])
df.select(dbf.st_astext(dbf.st_geogfromtext('wkt')).alias('result')).collect()
[Row(result='POINT Z (2.718281 3.141592 100)')]