hive-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Lefty Leverenz <leftylever...@gmail.com>
Subject Re: read a Hive Map without knowing keys
Date Tue, 18 Mar 2014 07:29:57 GMT
>  What is "select *?" ?

I think he just meant "select *" and ended the suggestion with a question
mark.

Admittedly, "select *?" looks like syntax with an extra wildcard.

-- Lefty


On Tue, Mar 18, 2014 at 3:07 AM, Szehon Ho <szehon@cloudera.com> wrote:

> You can try to check other string udf's for that case, here
> https://cwiki.apache.org/confluence/display/Hive/LanguageManual+UDF ,
> they will be in the section on string functions.
>
> Thanks
> Szehon
>
>
> On Mon, Mar 17, 2014 at 5:06 PM, Frank Luo <jluo@merkleinc.com> wrote:
>
>>  That is helpful, Thx!
>>
>>
>>
>> More dumb questions. What is "select *?" ?
>>
>>
>>
>> Also, any hints on how to find whether the map_keys contains a substring?
>> For example, supposing the map_keys contains emails, I want to see if one
>> of the emails contains "gmail.com".
>>
>>
>>
>> *From:* Szehon Ho [mailto:szehon@cloudera.com]
>> *Sent:* Monday, March 17, 2014 5:14 PM
>> *To:* user@hive.apache.org
>> *Subject:* Re: read a Hive Map without knowing keys
>>
>>
>>
>> Select *?  There are other built-in functions like map_keys and
>> map_values you can use in queries on maps.  Not sure if this addresses the
>> question.
>>
>> Thanks
>> Szehon
>>
>>
>>
>> On Mon, Mar 17, 2014 at 3:05 PM, Frank Luo <jluo@merkleinc.com> wrote:
>>
>> Is there a way to read Hive Map datatype without knowing keys?
>>
>>
>>
>> According to Hive document, the only way to read a Map is to access
>> through keys, ie:   myMap['myKey']. However, in many cases, the keys are
>> unknown, for example, HTable sparse columns, so in that kind of situation,
>> what is the ways to read the map?
>>
>>
>>
>
>

Mime
View raw message