Nóta
Teastaíonn údarú chun rochtain a fháil ar an leathanach seo. Is féidir leat triail a bhaint as shíniú isteach nó eolairí a athrú.
Teastaíonn údarú chun rochtain a fháil ar an leathanach seo. Is féidir leat triail a bhaint as eolairí a athrú.
Important
This feature is in Public Preview.
Parses the WKT description and returns the corresponding Geography value.
For the corresponding Databricks SQL function, see st_geogfromtext function.
Syntax
from pyspark.databricks.sql import functions as dbf
dbf.st_geogfromtext(col=<col>)
Parameters
| Parameter | Type | Description |
|---|---|---|
col |
pyspark.sql.Column or str |
A string value in WKT format, representing a Geography value. |
Examples
from pyspark.databricks.sql import functions as dbf
df = spark.createDataFrame([('POLYGON((0 0,5 6,7 -8,0 0))',)], ['wkt'])
df.select(dbf.st_astext(dbf.st_geogfromtext('wkt')).alias('result')).collect()
[Row(result='POLYGON((0 0,5 6,7 -8,0 0))')]