cancel
Showing results for 
Search instead for 
Did you mean: 
Data Engineering
Join discussions on data engineering best practices, architectures, and optimization strategies within the Databricks Community. Exchange insights and solutions with fellow data engineers.
cancel
Showing results for 
Search instead for 
Did you mean: 

How to handle , Error parsing WKT: Invalid coordinate value '180' found at position

swapnilmd
New Contributor II

DBR Version- 16.2
spark.databricks.geo.st.enabled true

SQL Query I am running:

 

 

%sql
WITH points (
    SELECT st_astext(st_point(30D, 10D)) AS point_geom
    UNION SELECT st_astext(st_point(10D, 90D)) AS point_geom
    UNION SELECT st_astext(st_point(40D, 40D)) AS point_geom)
SELECT st_geoglength(st_astext(st_makeline(collect_list(st_geomfromtext(point_geom)))))
FROM points

 

 


Full Error :
[WKT_PARSE_ERROR] Error parsing WKT: Invalid coordinate value '90' found at position 21 SQLSTATE: 22023


How to handle this error, how can I make this geometry compatible with databricks' st_* functions?
Note: st_isvalid is true for above geometry
1 REPLY 1

swapnilmd
New Contributor II

Also ,other geospatial libraries like apache sedona, supports these geometries.

Join Us as a Local Community Builder!

Passionate about hosting events and connecting people? Help us grow a vibrant local community—sign up today to get started!

Sign Up Now