Re: date datatype in hive

2012-06-28 Thread Gesli, Nicole
>On Wed, Jun 27, 2012 at 11:32 PM, Gesli, Nicole > wrote: >> Soham, I think you need something like this: >> >> SELECT ui.country, COUNT(1) >> FROM ( SELECT DISTINCT userid >> FROM users_audit >>WHERE SUBSTR(ua.logtime, 1, 17) >= '2

Re: date datatype in hive

2012-06-27 Thread Soham Sardar
7; >      ) ua >        JOIN >        users_info ui ON (ui.id = ua.userid) > GROUP BY >        ui.country; > > -Nicole > > From: Nitin Pawar > Reply-To: > Date: Wed, 27 Jun 2012 15:22:23 +0530 > > To: > Subject: Re: date datatype in hive > > soham, > > th

Re: date datatype in hive

2012-06-27 Thread Gesli, Nicole
JOIN users_info ui ON (ui.id = ua.userid) GROUP BY ui.country; -Nicole From: Nitin Pawar mailto:nitinpawar...@gmail.com>> Reply-To: mailto:user@hive.apache.org>> Date: Wed, 27 Jun 2012 15:22:23 +0530 To: mailto:user@hive.apache.org>> Subject: Re: date datatype in hi

Re: date datatype in hive

2012-06-27 Thread Nitin Pawar
> >> > well. Something like > >> > > >> > select country,name from users_info group by country; > >> > > >> > Regards > >> > Bejoy KS > >> > > >> > Sent from handheld, please excuse typos. > >&

Re: date datatype in hive

2012-06-27 Thread Soham Sardar
>> > >> > Regards >> > Bejoy KS >> > >> > Sent from handheld, please excuse typos. >> > >> > -Original Message- >> > From: Soham Sardar >> > Date: Wed, 27 Jun 2012 11:57:23 >> > To: ; Bejoy K

Re: date datatype in hive

2012-06-27 Thread Nitin Pawar
from handheld, please excuse typos. > > > > -Original Message- > > From: Soham Sardar > > Date: Wed, 27 Jun 2012 11:57:23 > > To: ; Bejoy Ks > > Reply-To: user@hive.apache.org > > Subject: Re: date datatype in hive > > > > And btw does grou

Re: date datatype in hive

2012-06-26 Thread Soham Sardar
27 Jun 2012 11:57:23 > To: ; Bejoy Ks > Reply-To: user@hive.apache.org > Subject: Re: date datatype in hive > > And btw does group by works in hive because the same wuery i am > running in mysql and its working fine but its failing in hive > > select name from users_info  

Re: date datatype in hive

2012-06-26 Thread Bejoy KS
To: ; Bejoy Ks Reply-To: user@hive.apache.org Subject: Re: date datatype in hive And btw does group by works in hive because the same wuery i am running in mysql and its working fine but its failing in hive select name from users_info group by country; in mysql its working but whn i try to run

Re: date datatype in hive

2012-06-26 Thread Soham Sardar
ly be satisfied with a few date functions on String >> data itself. >> >> Regards >> Bejoy KS >> >> >> >> From: Soham Sardar >> To: user@hive.apache.org; user >> Sent: Tuesday, June 26, 2012 2:23 PM &g

Re: date datatype in hive

2012-06-26 Thread Soham Sardar
ing > data itself. > > Regards > Bejoy KS > > > > From: Soham Sardar > To: user@hive.apache.org; user > Sent: Tuesday, June 26, 2012 2:23 PM > Subject: date datatype in hive > > I have a native data type in mysql and i just imported it into hive > and the data ty

Re: date datatype in hive

2012-06-26 Thread Bejoy Ks
on Mathematical functions. Your requirement can easily be satisfied with a few date functions on String data itself. Regards Bejoy KS From: Soham Sardar To: user@hive.apache.org; user Sent: Tuesday, June 26, 2012 2:23 PM Subject: date datatype in hive I

date datatype in hive

2012-06-26 Thread Soham Sardar
I have a native data type in mysql and i just imported it into hive and the data type of the column has now become string .. Now i would like to know if there is any native data type in hive and What are the pros and cons of using string type in hive rather than (int)(thats what i expect ) type An