hive-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Roberto Sanabria <robe...@stumbleupon.com>
Subject Re: Median in Hive
Date Wed, 18 Apr 2012 22:42:48 GMT
Sure, use this function:

percentile(BIGINT col, p)

and set p to be 0.5

Cheers,
R

On Wed, Apr 18, 2012 at 3:32 PM, sonia gehlot <sonia.gehlot@gmail.com>wrote:

> Hi Guys,
>
> Any idea, how to calculate median in Hive? Do we have any inbuilt function
> for it?
>
> Thanks for any help.
>
> Sonia
>

Mime
View raw message