variance aggregates per SQL:2003

From: Neil Conway <neilc(at)samurai(dot)com>
To: pgsql-patches <pgsql-patches(at)postgresql(dot)org>
Subject: variance aggregates per SQL:2003
Date: 2006-03-07 22:54:00
Message-ID: 1141772040.20504.5.camel@localhost.localdomain
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-patches

This patch implements some new aggregate functions defined by SQL2003:
stddev_pop(), stddev_samp(), var_pop(), and var_samp(). stddev_samp()
and var_samp() are identical to the existing stddev() and variance()
aggregates, so I've made the latter aliases for the former.

I noticed that SQL2003 does not allow DISTINCT to be specified for these
aggregate functions. I can't really see the rationale for this
restriction, and it would be fairly ugly to implement as far as I can
tell. Thoughts?

-Neil

Attachment Content-Type Size
variance_aggs-2.patch text/x-patch 34.2 KB

Responses

Browse pgsql-patches by date

  From Date Subject
Next Message Mark Kirkwood 2006-03-07 23:24:22 Re: pg_freespacemap question
Previous Message Alvaro Herrera 2006-03-07 22:28:40 Re: CREATE SYNONYM ...