Re: what's wrong with this code?

From: Merlin Moncure <mmoncure(at)gmail(dot)com>
To: Jude DaShiell <jdashiel(at)panix(dot)com>
Cc: Andrej <andrej(dot)groups(at)gmail(dot)com>, pgsql-novice <pgsql-novice(at)postgresql(dot)org>
Subject: Re: what's wrong with this code?
Date: 2015-06-22 12:41:59
Message-ID: CAHyXU0wkDQ5USA+ost6sS+xYHiMGYau+soqQROm5W8h4ET4N7g@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

On Mon, Jun 22, 2015 at 5:12 AM, Jude DaShiell <jdashiel(at)panix(dot)com> wrote:
> In any case, if it's legal I can probably do the median calculations in an
> easier way or what may be easer. If the min and max values for each field
> can be inserted into a temporary table under different field names with
> numeric(3,1) types then it ought to be possible to sum the min and max
> values in that temporary table and divide by 2 to get the medians. So far,
> I've not heard of anyone doing anything like this with the min and max
> calculated values. With my luck though I'd be arrested by the psql Police
> for some violation trying this.

<aside: please try to avoid top posting>

postgres does support median. see:
http://www.postgresql.org/docs/9.4/static/functions-aggregate.html#FUNCTIONS-ORDEREDSET-TABLE

merlin

In response to

Browse pgsql-novice by date

  From Date Subject
Next Message Pascal Cloup 2015-06-23 13:33:52 large objects
Previous Message Jude DaShiell 2015-06-22 10:12:32 Re: what's wrong with this code?