Ian Burrell <imb@rentrak.com> writes:
> We are doing things in the aggregates that make them troublesome when
> called the ffunc is called multiple times. The state structure uses a
> lot of memory for intermediate work. The memory needs to be freed as
> soon as possible otherwise there is a danger of running of out memory.
Possibly you should just force enable_hashagg off, if you are concerned
about memory usage. ISTM that running multiple transvalue calculations
in parallel is a bad idea from the start, if you are feeling that tense
about the amount of memory that will be chewed up by just one.
regards, tom lane