hive-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Jörn Franke <jornfra...@gmail.com>
Subject Re: if else condition in hive
Date Tue, 21 Jun 2016 17:11:01 GMT
I recommend you to rethink it as part of a bulk transfer potentially even using separate partitions.
Will be much faster.

> On 21 Jun 2016, at 13:22, raj hive <raj.hiveql@gmail.com> wrote:
> 
> Hi friends,
> 
> INSERT,UPDATE,DELETE commands are working fine in my Hive environment after changing
the configuration and all. Now, I have to execute a query like below sql  in hive.
> 
> If exists(select * from tablename where columnname=something)
>   update table set column1=something where columnname=something
>  else
>   insert into tablename values ...
> 
> Can any one help me how to do it in Hive? 
> 
> Thanks
> Raj

Mime
View raw message