Support Questions

Find answers, ask questions, and share your expertise
Celebrating as our community reaches 100,000 members! Thank you!

How to update bulk records in Hive without using Merge


We have Hive 2.1 in our system and looking to update bulk records daily once. I see there is a feature called merge in hive 2.2 which will solve this purpose. But is there any way I can update bulk records in lower versions using Hive Transactions.



@Harish Nerella

You can use usual hive update to update bulk records:

Merge is more flexible and a bit different than a plain update. But if you are only performing only updates I do not see any reason not be able to do it using update statement from Hive 0.14.


@rbiswasThank you for your answer.

I think with the help of update statement we can update multiple columns of a record for a specific where clause. And we can use where clause for a set of matching values using IN to update column values in multiple records with the same value. But I have a situation where I need to update multiple columns of multiple records with a set of values. Something like a similar kind of Merge operation where I need to retrieve the values from another hive table and update the transaction table. As far as I know update feature will not allow sub queries.

Is there any other way which I am missing for this scenario?