Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to access Hive using a Java API

Tags:

hive

http://wiki.apache.org/hadoop/Hive/HiveJDBCInterface - Is there a higher level ORM interface than the Hive JDBC driver which we can use to run the queries and parse the results

like image 896
priya Avatar asked Feb 21 '23 00:02

priya


1 Answers

No. The "R" in ORM stands for a "relational database". Hive is a NOSQL databse, not a relational database. It's a huge advantage of Hive comparing to many other NOSQL databases that you can access it using (almost) normal SQL and using (almost) full featured standard JDBC interface. But if you are thinking about using ORM and Hive together, you might be approaching your problem from an incorrect angle.

EDIT 6/4/13: Here's a quote from Wikipedia: In the relational model, each table schema must identify a primary column used for identifying a row called the primary key. Tables can relate by using a foreign key that points to the primary key.

Hive does not support neither foreign nor primary keys, so it is not a relational database.

I would like to thank the downvoter for giving me an opportunity to doublecheck the reasoning that led to making my original statement.

like image 137
Olaf Avatar answered Feb 22 '23 23:02

Olaf