I have written code (java) for the conversion of EBCDIC to ASCII on the local machine. And we are writing a serde for hive query which would provide the ability for Hive to read the EBCDIC file and convert it into ASCII file at run time. So that's why we are writing a SerDe. So how to integrate this code on. Local machine to SerDe.
Asked
Active
Viewed 119 times
1 Answers
1
how to integrate this code on. Local machine to SerDe ?
Your class must implement org.apache.hadoop.hive.serde2.SerDe
then you need to build the jar and move it cluster
- Now include the JAR in
ADD JAR <jar/location/in/cluster>
Use class SerDe class in TABLE CREATION or ALTERING like below
ROW FORMAT SERDE 'classpath.of.implemented.SerDe.in.jar'

mrsrinivas
- 34,112
- 13
- 125
- 125
-
thank you .could you please elaborate on how to implement org.apache.hadoop.hive.serde2.SerDe – tejas bharambe Jan 30 '17 at 07:28
-
[Above added link](http://blog.cloudera.com/blog/2012/12/how-to-use-a-serde-in-apache-hive/) have an example in it with a heading **Developing a SerDe** – mrsrinivas Jan 30 '17 at 08:02