Re: Case inside select statement in hive

2014-12-16 Thread Daniel Haviv
Hi, Please RTFM before asking questions. Taken from https://cwiki.apache.org/confluence/display/Hive/LanguageManual+UDF: Conditional Functions *Return Type* *Name(Signature)* *Description* T if(boolean testCondition, T valueTrue, T valueFalseOrNull) Returns valueTrue when testCondition is tru

Fwd: Case inside select statement in hive

2014-12-16 Thread Gayathri Swaroop
I use hive 0.12.0. -- Forwarded message -- From: Gayathri Swaroop Date: Tue, Dec 16, 2014 at 10:37 AM Subject: Case inside select statement in hive To: user Hi, I have oracle query which i want to hit against a hive table. The oracle query has a case if exists select would this

Case inside select statement in hive

2014-12-16 Thread Gayathri Swaroop
Hi, I have oracle query which i want to hit against a hive table. The oracle query has a case if exists select would this work in hive? This is my oracle query that needs to be converted to hive. select distinct CONTR.BMF_PARTNER_ID AS BMF_BMF_PARTNER_ID, CONTR.BUSINESS_PARTNER AS