Return-Path: X-Original-To: apmail-hive-user-archive@www.apache.org Delivered-To: apmail-hive-user-archive@www.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 1427ADC27 for ; Sat, 4 Aug 2012 06:53:27 +0000 (UTC) Received: (qmail 43865 invoked by uid 500); 4 Aug 2012 06:53:25 -0000 Delivered-To: apmail-hive-user-archive@hive.apache.org Received: (qmail 43831 invoked by uid 500); 4 Aug 2012 06:53:25 -0000 Mailing-List: contact user-help@hive.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: user@hive.apache.org Delivered-To: mailing list user@hive.apache.org Received: (qmail 43789 invoked by uid 99); 4 Aug 2012 06:53:24 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Sat, 04 Aug 2012 06:53:24 +0000 X-ASF-Spam-Status: No, hits=4.7 required=5.0 tests=FREEMAIL_FORGED_REPLYTO,FSL_FREEMAIL_1,FSL_FREEMAIL_2,HTML_MESSAGE,RCVD_IN_DNSWL_NONE,SPF_PASS X-Spam-Check-By: apache.org Received-SPF: pass (nike.apache.org: local policy) Received: from [98.138.91.172] (HELO nm12-vm4.bullet.mail.ne1.yahoo.com) (98.138.91.172) by apache.org (qpsmtpd/0.29) with SMTP; Sat, 04 Aug 2012 06:53:14 +0000 Received: from [98.138.90.51] by nm12.bullet.mail.ne1.yahoo.com with NNFMP; 04 Aug 2012 06:52:52 -0000 Received: from [98.138.89.232] by tm4.bullet.mail.ne1.yahoo.com with NNFMP; 04 Aug 2012 06:52:52 -0000 Received: from [127.0.0.1] by omp1047.mail.ne1.yahoo.com with NNFMP; 04 Aug 2012 06:52:52 -0000 X-Yahoo-Newman-Property: ymail-3 X-Yahoo-Newman-Id: 562910.40979.bm@omp1047.mail.ne1.yahoo.com Received: (qmail 96297 invoked by uid 60001); 4 Aug 2012 06:52:52 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=yahoo.com; s=s1024; t=1344063172; bh=gEduA080F02DbARzfQcHXcMcJCPNVZDCKHaC8RpFcWc=; h=X-YMail-OSG:Received:X-Mailer:References:Message-ID:Date:From:Reply-To:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=08HtmarZM+jldxBrighVEqkwQ5G4O4D3nVSAOqd5NlIkUggegcja50KpkKoE9EjsxP4ukaPKCXrL9yj73fJ0QtTVMXTS2uHhcg1ystg68bivI7pQ8MvEH7TwK6U5Qf/IfJ+26fBOV+ImEotrSKtzsOSaabkkegfISWDiJBrD4aA= DomainKey-Signature: a=rsa-sha1; q=dns; c=nofws; s=s1024; d=yahoo.com; h=X-YMail-OSG:Received:X-Mailer:References:Message-ID:Date:From:Reply-To:Subject:To:In-Reply-To:MIME-Version:Content-Type; b=IRSoeY7hEbiwZd0Tjj1V4rYk7sC7Ab0F1hJv/ZfjLAQCBY5COq3E2sns3TE4f+B9qkcMTwZSBGE1FXIl+BVgPyyR8uEnQWGw7ZJFbcrQig27a22PmAHiu5ebHXv60hnp31CWaT4IMzN4fWG/7sBqk87VV6SDaxKSu+w24W/zu4E=; X-YMail-OSG: QL0aLjoVM1lUsGSb.wNVnjAKBeUdpxprmVKp4c2veO9MDVG .GOwD3dmNCpGAokM6MdUQV9fGJRjjWRX8UAQJgqeaK3zZTBxdg4grgznxZvy Y58Ifg1bUQngezrC0CintkF.o2wduclIzlUTkLsV89SW7K3FIUv8Bsc0Bneg d1destPdvAxHVbjS1Jqk2IQBdd0HbuGPtExhbHTs_dW1bMepQ..ZxGIEBFPL Lhs5FoCPx43V49MP7oE1f_OzYDV_w0k0kzzYtVc0NMkrwEU2VSjMPpuVREjE qe9OnLhphUJY9DDlTyr7.kyoE9tdHC4s7K9E8uxLnqhdwHeUb6LB7vjKEdFN 3wLWy5rw.3lPAUviyA5bW40LoDp66JMeUh3zLMyAl10R37EwKDPYc8lrbLa. n9LVT5POHz7DZnMZRqkV4XS172FASXZU07ZcUFwtBo_JsOBQCp3km3Iiaq7x m.qhnzEFuWM32bZQyuROESMUWTTAilcW0P7DvYT6d9Tey_lrjP851Np9zSBs b8PUfndySbvFFs3pafzzPiOSCFIlpqvXNUs8Z5bcza9q.4TDy7jlUtJd1DwY ofZPtCKJWmwg2849X5Kz45jq3JQ-- Received: from [59.93.35.63] by web121204.mail.ne1.yahoo.com via HTTP; Fri, 03 Aug 2012 23:52:52 PDT X-Mailer: YahooMailWebService/0.8.120.356233 References: Message-ID: <1344063172.96161.YahooMailNeo@web121204.mail.ne1.yahoo.com> Date: Fri, 3 Aug 2012 23:52:52 -0700 (PDT) From: Bejoy Ks Reply-To: Bejoy Ks Subject: Re: Passing date as command line arguments To: "user@hive.apache.org" In-Reply-To: MIME-Version: 1.0 Content-Type: multipart/alternative; boundary="-944809811-297493799-1344063172=:96161" ---944809811-297493799-1344063172=:96161 Content-Type: text/plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable Hi Techy=0A=0AAre you getting the results for the same query directly from = CLI, I mean does the below query return correct results=0Aselect * from lip= _data_quality where dt =3D '20120709';=A0=0A=0A=0AIf the above query return= s results, can you check the hive logs and see what is the actual query bei= ng executed?=0A=A0=0ARegards,=0ABejoy KS=0A=0A=0A__________________________= ______=0A From: Techy Teck =0ATo: user@hive.apache= .org =0ACc: Vijay Dirisala =0ASent: Saturday, August 4, = 2012 12:11 PM=0ASubject: Re: Passing date as command line arguments=0A =0A= =0AThanks Vijay for the suggestion. I also tried that and it still didn't w= orked for me.=0A=0AAny thoughts why it is not working?=0A=0A=0A=0A=0A=0AOn = Fri, Aug 3, 2012 at 11:32 PM, Vijay wrote:=0A=0AThere ca= n't be a space in the variable name. Try this: ${hiveconf:start_date}=0A>= =0A>=0A>On Fri, Aug 3, 2012 at 11:06 PM, Techy Teck wrote:=0A>> Can anyone help me out on this?=0A>>=0A>> I am stuck on this= and I have no clue what wrong I am doing?=0A>>=0A>>=0A>>=0A>>=0A>> On Fri,= Aug 3, 2012 at 3:48 PM, Techy Teck wrote:=0A>>>= =0A>>> I have my below query in test1.hql file. I am trying to pass the dat= e (dt)=0A>>> as the command line argument.=0A>>>=0A>>>=0A>>> select * from = lip_data_quality where dt =3D '${hiveconf: start_date}';=0A>>>=0A>>>=0A>>> = So whenever I try to run the above test1.hql file like this-=0A>>>=0A>>> = =A0hive -f hivetest1.hql -hiveconf start_date=3D20120709=0A>>>=0A>>> I get = zero records back. But the data is there in that table for that=0A>>> date.= Why is it so? Something wrong I am doing?=0A>>>=0A>>> Can anyone help me o= ut here? I was following Bejoy's Article here=0A>>> http://kickstarthadoop.= blogspot.com/2011/10/include-values-during-execution-time-in.html=0A>>>=0A>= >>=0A>>=0A> ---944809811-297493799-1344063172=:96161 Content-Type: text/html; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable
Hi Tec= hy

Are you getting the results for the same query directly from CLI, I mea= n does the below query return correct results
select * from lip_data_quality where dt =3D '201= 20709'; 

If the above query returns results, can you check the hive logs and see what is the actual query being executed?
 
Regards,
Bejoy KS


From: Techy Teck <comptechgeeky@gmail.= com>
To: user@hive.= apache.org
Cc: Vijay D= irisala <techvd@gmail.com>
Sent: Saturday, August 4, 2012 12:11 PM
Subject: Re: Passing date as command line arguments
=

=0A
Thanks Vijay for the suggestion. I also = tried that and it still didn't worked for me.

Any though= ts why it is not working?




<= div class=3D"yiv1167688165gmail_quote">On Fri, Aug 3, 2012 at 11:32 PM, Vij= ay <techvd@gmail.com> wrote:
=0A
The= re can't be a space in the variable name. Try this: ${hiveconf:start_date}<= br>=0A
=0AOn Fri, Aug 3, 2012 at 11:06 PM, Techy Teck <comptechgeeky@gmail.com> wrote:
=0A> Ca= n anyone help me out on this?
=0A>
=0A> I am stuck on this and = I have no clue what wrong I am doing?
=0A>
=0A>
=0A>
= =0A>
=0A> On Fri, Aug 3, 2012 at 3:48 PM, Techy Teck <comptechgeeky@gmail.com> wrote:=
=0A>>
=0A>> I have my below query in test1.hql file. I a= m trying to pass the date (dt)
=0A>> as the command line argument.=
=0A>>
=0A>>
=0A>> select * from lip_data_qualit= y where dt =3D '${hiveconf: start_date}';
=0A>>
=0A>>
= =0A>> So whenever I try to run the above test1.hql file like this-=0A>>
=0A>>  hive -f hivetest1.hql -hiveconf start_dat= e=3D20120709
=0A>>
=0A>> I get zero records back. But the= data is there in that table for that
=0A>> date. Why is it so? So= mething wrong I am doing?
=0A>>
=0A>> Can anyone help me = out here? I was following Bejoy's Article here
=0A>> http://kickst= arthadoop.blogspot.com/2011/10/include-values-during-execution-time-in.html=
=0A=0A>>
=0A>>
=0A>
=0A

=0A


---944809811-297493799-1344063172=:96161--