Re: Median Function?

From: Anup Jalan <anup.jalan_at_rave-tech.com>
Date: 24 Jan 2003 02:39:16 -0800
Message-ID: <532afd4.0301240239.1a278a1a_at_posting.google.com>


select barcode, percentile_cont(0.5) within group (order by s635 desc) from raw_data
group by barcode ;

or

select barcode, percentile_disc(0.5) within group (order by s635 desc) from raw_data
group by barcode ;

Anup Jalan
Rave Technologies
www.rave-tech.com

"Okey Laboratory" <itatsumakiNO_at_SPAMhotmail.com> wrote in message news:<H96vxF.3Kq_at_campus-news-reading.utoronto.ca>...
> Hi all,
>
> Oracle does not seem to have a "Median" function. Am I just missing it, or
> is there some easy way to implement it? I would like to be able to do
> something like:
>
> select barcode, median(s635)
> from raw_data
> group by barcode;
>
> Any suggestions very much appreciated!
> Paul
Received on Fri Jan 24 2003 - 11:39:16 CET

Original text of this message