Support Questions

Find answers, ask questions, and share your expertise

How to store ST_GEOMETRY data type in Hive

avatar
Contributor

How to store ST_GEOMETRY data type in Hive

1 ACCEPTED SOLUTION

avatar

Hi Gaurav,

That looks like a datatype from Esri Spatial framework . Looking at the docs, you can store a geometry as OGC well-known text (=String) and read it back as a ST_GEOMETRY with the UDF st_geomfromtext: https://github.com/Esri/spatial-framework-for-hadoop/wiki/UDF-Constructors#st_geomfromtext

Regards,

Ward

View solution in original post

3 REPLIES 3

avatar
Contributor

Kindly let me know the resolution for storing ST_GEOMETRY data type in Hive

avatar

Hi Gaurav,

That looks like a datatype from Esri Spatial framework . Looking at the docs, you can store a geometry as OGC well-known text (=String) and read it back as a ST_GEOMETRY with the UDF st_geomfromtext: https://github.com/Esri/spatial-framework-for-hadoop/wiki/UDF-Constructors#st_geomfromtext

Regards,

Ward

avatar
Contributor

Thanks Ward !! Currently the Spatial data is stored in oracle with data type as ST_GEOMETRY. I have checked in hive, we can't store ST_GEOMETRY datatype. All what we have to do is to change the data type in oracle and store in hive. Now changing the data type in oracle is again a big challenge as ST_AsText(ST_Geometry) or any other function don't work in oracle.