0
votes

I am trying to upload json file on hadoop using json serde. I have uploaded jar lib to hadoop but getting error while running hive command

I have uploaded json serde jar file to /apps/hive/warehouse/lib path.Now, when i am tring to run this command

ADD JAR /apps/hive/warehouse/lib/json-serde-1.3-jar-with-dependencies.jar;

I got this error

H110 Unable to submit statement. Error while processing statement: /apps/hive/warehouse/lib/json-serde-1.3.7-SNAPSHOT-jar-with-dependencies.jar does not exist [ERROR_STATUS]

2

2 Answers

0
votes

Looks like your jar is in HDFS location. Use:

add jar hdfs:///apps/hive/warehouse/lib/json-serde-1.3-jar-with-dependencies.jar;
0
votes

Try to use URL (add file//) before filename:

ADD JAR file///apps/hive/warehouse/lib/json-serde-1.3-jar-with-dependencies.jar;

Also you should be able to add jar from a repository if your Hive is 1.2.0 and above.