Closed Andarius closed 3 years ago
Spatial-Framework documentation says ST_MultiPolygon(array(x1, y1, x2, y2, ... ), array(x1, y1, x2, y2, ... ), ... ), so it looks like st_multipolygon(geometry.coordinates[0][0][0], geometry.coordinates[0][0][1], ...)
passes array<double> as expected and works correctly.
Maybe the only oddity is - is Spark-SQL presenting a botched error message?
Cross-reference #36, #126.
Try ST_GeomFromGeoJson
.
I'm trying to load a valid Geojson file using SPARK SQL and then transforming the coordinates to ST_MultiPolygon.
The jars I use are:
The schema of the input data is:
The process fails when I try the following:
I get:
No handler for Hive UDF 'com.esri.hadoop.hive.ST_MultiPolygon': org.apache.hadoop.hive.ql.exec.NoMatchingMethodException: No matching method for class com.esri.hadoop.hive.ST_MultiPolygon with (array<array<double>>). Possible choices: _FUNC_(array<array<double>>) _FUNC_(string) ;
So I pass an array<array> and it expects an array<array> .
It works if I try:
Any idea of what's wrong (or what I'm doing wrong ?)