Re: Idea for aggregates - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Idea for aggregates
Date
Msg-id 10310.1396651677@sss.pgh.pa.us
Whole thread Raw
In response to Idea for aggregates  (Greg Stark <stark@mit.edu>)
Responses Re: Idea for aggregates  (Greg Stark <stark@mit.edu>)
List pgsql-hackers
Greg Stark <stark@mit.edu> writes:
> The basic idea is to separate the all the properties of the aggregate
> functions except the final function from the final function into a
> separate object. Giving the optimizer the knowledge that multiple
> aggregate functions use the share the same basic machinery and
> semantics for the state is the magic sauce that's a prerequisite for
> the several ideas we were each thinking of.

Why exactly do you need to invent an "aggregate class" concept for this?
Can't the planner just look in pg_aggregate to see that the
sfunc/stype/initcond are the same for two different aggregates?
        regards, tom lane



pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: [review] PostgreSQL Service on Windows does not start if data directory given is relative path
Next
From: Tom Lane
Date:
Subject: Re: [bug fix] pg_ctl always uses the same event source