Our Community is getting an upgrade! To get everything ready for the relaunch, we’ll be placing the site in read-only mode starting September 21st.
We really appreciate your understanding while we get things set up behind the scenes. Catch up on all the exciting details about the move here.
Need help or have questions? Drop us a line at [email protected]

Archives of Support Questions (Read Only)

This is an archived board for historical reference. Information and links may no longer be available or relevant
Announcements
This board is archived and read-only for historical reference. To ask a new question, please post a new topic on the appropriate active board.

how hive can read Hbase current and previous versions data?

avatar
Rising Star
 
1 ACCEPTED SOLUTION

avatar
Master Guru

As far as I know, Hive can read only the current (most recent) data version in HBase. Only when using HBase API or hbase shell you can also read all versions, or only the ones in a specific time interval.

From the Hive HBase integration document: there is currently no way to access the HBase timestamp attribute, and queries always access data with the latest timestamp.

View solution in original post

6 REPLIES 6

avatar
Master Guru

As far as I know, Hive can read only the current (most recent) data version in HBase. Only when using HBase API or hbase shell you can also read all versions, or only the ones in a specific time interval.

From the Hive HBase integration document: there is currently no way to access the HBase timestamp attribute, and queries always access data with the latest timestamp.

avatar
Rising Star

Thanks for replying.

if not hive can impala read all versions in HBase?

avatar
Master Guru

No, Impala cannot read all versions either. Impala defines tables in HBase using Hive DDL because Impala doesn't support custom SerDe's to define tables, and as we saw Hive doesn't expose HBase timestamps (more detail about Impala and HBase here). So, if you want to access timestamps you have to make them "first class citizens" and include them in your Hbase table key, or among values, if you can ensure unique keys by other means.

avatar
Rising Star

thank you 🙂

avatar
Master Guru

Okay, no problems, please consider to accept the answer, to help us manage answered questions. Tnx!

avatar
Super Guru

currently there is no way available to read all the versions data.