You are viewing a plain text version of this content. The canonical link for it is here.
Posted to user@hive.apache.org by Gary Zhao <ga...@gmail.com> on 2013/09/24 01:35:44 UTC

Is there a way to check if a column exists or not?

Hello

I'm query a table and I'm able to filter column value is "NULL", but looks
like some record doesn't even have "NULL" value. Is there a way to filter
them out?

Thanks
Gary

Re: Is there a way to check if a column exists or not?

Posted by Gary Zhao <ga...@gmail.com>.
Thanks. Seems like it's an empty string.


On Tue, Sep 24, 2013 at 7:35 AM, Stephen Sprague <sp...@gmail.com> wrote:

> i think we need an example.  if the column exists in the meta-data but not
> in the data i'm pretty sure hive will take it as a null.  no example though
> makes it hard to go further into this (at least for this reader.)
>
>
> On Mon, Sep 23, 2013 at 4:35 PM, Gary Zhao <ga...@gmail.com> wrote:
>
>> Hello
>>
>> I'm query a table and I'm able to filter column value is "NULL", but
>> looks like some record doesn't even have "NULL" value. Is there a way to
>> filter them out?
>>
>> Thanks
>> Gary
>>
>
>

Re: Is there a way to check if a column exists or not?

Posted by Stephen Sprague <sp...@gmail.com>.
i think we need an example.  if the column exists in the meta-data but not
in the data i'm pretty sure hive will take it as a null.  no example though
makes it hard to go further into this (at least for this reader.)


On Mon, Sep 23, 2013 at 4:35 PM, Gary Zhao <ga...@gmail.com> wrote:

> Hello
>
> I'm query a table and I'm able to filter column value is "NULL", but looks
> like some record doesn't even have "NULL" value. Is there a way to filter
> them out?
>
> Thanks
> Gary
>