pgsql: In CREATE AGGREGATE, allow the transition datatype to be

From: tgl(at)postgresql(dot)org (Tom Lane)
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: In CREATE AGGREGATE, allow the transition datatype to be
Date: 2008-11-14 19:47:50
Message-ID: 20081114194750.AEAFB7545A4@cvs.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Log Message:
-----------
In CREATE AGGREGATE, allow the transition datatype to be "internal", but only
if the user is superuser. This makes available to extension modules the same
sort of trick being practiced by array_agg(). The reason for the superuser
restriction is that you could crash the system by connecting up an
incompatible pair of internal-using functions as an aggregate. It shouldn't
interfere with any legitimate use, since you'd have to be superuser to create
the internal-using transition and final functions anyway.

Modified Files:
--------------
pgsql/src/backend/catalog:
pg_aggregate.c (r1.96 -> r1.97)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/catalog/pg_aggregate.c?r1=1.96&r2=1.97)
pgsql/src/backend/commands:
aggregatecmds.c (r1.46 -> r1.47)
(http://anoncvs.postgresql.org/cvsweb.cgi/pgsql/src/backend/commands/aggregatecmds.c?r1=1.46&r2=1.47)

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2008-11-14 19:58:45 pgsql: Reduce contrib/intagg to a thin wrapper around the new core
Previous Message Tom Lane 2008-11-14 19:42:57 Re: pgsql: Enable script to generate preproc.y in build process.