-Re: Small question
Abhishek 2012-10-12, 16:54
Thanks Arun you are right.
Sent from my iPhone
On Oct 12, 2012, at 11:26 AM, Arun Ahuja <[EMAIL PROTECTED]> wrote:
> From my interpretation Hive coaelsce returns the first non-null value.
> So it seems you are just doing a null check on x and return y if it is
> null and z otherwise?
> In Pig you could do something like --- " (x is null ? y : z) This a
> standard ternary if/else. Don't see if the 0.00 actually plays any
> other role than the null check, right?
> On Fri, Oct 12, 2012 at 10:05 AM, Abhishek <[EMAIL PROTECTED]> wrote:
>> Hi all,
>> How to Hive coalesce statement in pig
>> Case when
>> Coalesce(x,0.00)=0.00 then y else z
>> How to write this in pig