Howdy,
I've sent the following to Jan Weick, but haven't heard a reply. Thought I'd
send it to the list to see if others are having the same problem, and to see
if any Postgres developer reading this list will take ownership for this
problem:
I've found I've had to do a lot of plpgsql rewriting to avoid memory
exhaustion due to calling the functions multiple times in the one session.
Specifically, I've found that huge memory leaks occur when variables are
re-assigned based on a previous value (ie var := var + 1), and also when
strings are concatenated. Worse still is when you use the concatenation to
append to an existing variable.
Careful coding (plus extra memory and swap space!) has allowed us to still
be using Postgres, but it is a bit worrying that plpgsql can't even do
i:=i+1 reliably. It would be nice to know if this could be addressed prior
to the 7.1 release.
Regards,
Chris Knight
Systems Administrator
AIMS Independent Computer Professionals
Tel: +61 3 6334 6664 Fax: +61 3 6331 7032 Mob: +61 419 528 795
Web: http://www.aims.com.au