Re: out of memory error on a delete command

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: out of memory error on a delete command
Дата
Msg-id 27576.1121262629@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: out of memory error on a delete command  (Csaba Nagy <nagy@ecircle-ag.com>)
Список pgsql-jdbc
Csaba Nagy <nagy@ecircle-ag.com> writes:
> This is interesting... we actually do have a trigger on that table which
> inserts a record in a kind of archive table for each deleted record. I
> actually forgot about this, good that you reminded me :-)
> But then the TRUNCATE worked fine, and the table was actually truncated,
> and I'm sure the trigger didn't kick in at all. Is this something
> unexpected ?
> The trigger itself is a BEFORE DELETE ... FOR EACH ROW trigger, and it's
> not deferred. I've checked the table too where the trigger inserts, and
> it had indeed a few records, but not as many as the original table had.
> That could though come from previous runs...

If it's a BEFORE trigger then the pending-trigger list isn't at issue.
It sounds to me like the trigger function itself is doing something that
leaks a little memory per firing.  You could learn more by looking in
the postmaster log: there should be a verbose report of memory context
sizes put there at the time of the "out of memory" error report.

            regards, tom lane

В списке pgsql-jdbc по дате отправления:

Предыдущее
От: Csaba Nagy
Дата:
Сообщение: Re: out of memory error on a delete command
Следующее
От: Kris Jurka
Дата:
Сообщение: Re: patch to fix jdk 2 compile errors and v2 compatability