Grokbase Groups Hive user July 2010
FAQ
hive> describe spect;
describe spect;
OK
url string
key string
crawler struct<domain:string,component:string,http_headers:string,machine:string,proxy:string,crawl_time:bigint>
dust struct<in_the_system:boolean,urls:array<string>>
Time taken: 0.046 seconds

hive>select crawler.domain from spect;
OK
domain
domain2
domain3
domain4
domain5
domain
domain2
domain3
domain4
domain5
domain_failed
Time taken: 17.183 seconds

HOWEVER, now when I try to fire the query where crawler.domain , I get blank answer , no records.
hive>select crawler.domain , dust.in_the_system from spect where crawler.domain like '%1';
OK
Time taken: 5.442 seconds
hive>select crawler.domain , dust.in_the_system from specttacles where crawler.domain ='domain1';
OK
Time taken: 5.457 seconds
hive>


pl help. How can I query fields in struct ?
OR wht I am doing wrong here

-Sagar

Search Discussions

  • Kumar Saurabh at Jul 19, 2010 at 3:17 am
    I am not a hive expert, but in the result for the following query --

    select crawler.domain from spect;

    you dont get any rows that end with 1.

    is it simply a case that your data does not match the query?

    kumar
    On Sun, Jul 18, 2010 at 8:11 PM, Sagar Naik wrote:
    hive> describe spect;
    describe spect;
    OK
    url string
    key string
    crawler
    struct<domain:string,component:string,http_headers:string,machine:string,proxy:string,crawl_time:bigint>
    dust struct<in_the_system:boolean,urls:array<string>>
    Time taken: 0.046 seconds
    hive>select crawler.domain from spect;
    OK
    domain
    domain2
    domain3
    domain4
    domain5
    domain
    domain2
    domain3
    domain4
    domain5
    domain_failed
    Time taken: 17.183 seconds
    HOWEVER, now when I try to fire the query where crawler.domain , I get blank
    answer , no records.
    hive>select crawler.domain , dust.in_the_system from spect where
    crawler.domain like '%1';
    OK
    Time taken: 5.442 seconds
    hive>select crawler.domain , dust.in_the_system from specttacles where
    crawler.domain ='domain1';
    OK
    Time taken: 5.457 seconds
    hive>

    pl help. How can I query fields in struct ?
    OR wht I am doing wrong here
    -Sagar

Related Discussions

Discussion Navigation
viewthread | post
Discussion Overview
groupuser @
categorieshive, hadoop
postedJul 19, '10 at 3:13a
activeJul 19, '10 at 3:17a
posts2
users2
websitehive.apache.org

2 users in discussion

Kumar Saurabh: 1 post Sagar Naik: 1 post

People

Translate

site design / logo © 2021 Grokbase