I have the following dataframe
------------------------------------------------------
|longitude | latitude | geomType | geom |
------------------------------------------------------
|-7.0737816 |33.82666166|Polygon |[GEOMETRY - 113 o]|
-------------------------------------------------------
I want to apply this query on this dataframe
I use the folowing code
dataframe= sparkSession.sql("select ST_GeomFromText('POINT("+col("longitude")+" , '',"+col("latitude")+")')");
I get this error
Exception in thread "main" org.apache.spark.sql.AnalysisException: Undefined function: 'ST_GeomFromText'. This function is neither a registered temporary function nor a permanent function registered in the database 'default'.
Note that I'm using java language on spark
I need your help .
Thank you