Home | About | Sematext search-lucene.com search-hadoop.com
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB
 Search Hadoop and all its subprojects:

Switch to Threaded View
Hive >> mail # user >> Rolling MAU computation


Copy link to this message
-
Re: Rolling MAU computation
An example would be awesome .. I've never used a map side join (though I'm
searching on that now .. )

Tom

On Wed, Oct 10, 2012 at 3:59 PM, Roberto Sanabria
<[EMAIL PROTECTED]>wrote:

> I've done this with a map side join using a table that stores days of the
> week. I use that to drive the day im calculating the count for. Let me know
> if you need an example.
>
> Cheers,
> R
>
>
> On Wed, Oct 10, 2012 at 3:05 PM, Tom Hubina <[EMAIL PROTECTED]> wrote:
>
>> I'm trying to compute the number of active users in the previous 30 days
>> for each day over a date range. I can't think of any way to do it directly
>> within Hive so I'm wondering if you guys have any ideas.
>>
>> Basically the algorithm is something like:
>>
>> For each day in date range:
>>    SELECT day, COUNT(DISTINCT(userid)) FROM logins WHERE day - logins.day
>> < 30;
>>
>>  Thanks for your help!
>>
>> Tom
>>
>>
>
NEW: Monitor These Apps!
elasticsearch, apache solr, apache hbase, hadoop, redis, casssandra, amazon cloudwatch, mysql, memcached, apache kafka, apache zookeeper, apache storm, ubuntu, centOS, red hat, debian, puppet labs, java, senseiDB