Bruce Momjian <pgman@candle.pha.pa.us> writes:
>> Seems like a pretty serious (not to say fatal) objection to me. Surely
>> you can fix that.
> OK, suggestions. I know CommandCounterIncrement will not help. Should
> I do more pfree'ing?
No, retail pfree'ing is not a maintainable solution. I was thinking
more along the lines of a MemoryContextResetAndDeleteChildren() on
whatever the active context is. If that doesn't work straight off,
you might have to create a new working context and switch into it
before calling the analyze subroutine --- then deleting that context
would do the trick.
regards, tom lane