From: | Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> |
---|---|
To: | "Casey Duncan" <casey(at)pandora(dot)com> |
Cc: | pgsql-bugs(at)postgresql(dot)org |
Subject: | Re: BUG #2428: ERROR: out of memory, running INSERT SELECT statement |
Date: | 2006-05-10 04:09:28 |
Message-ID: | 25997.1147234168@sss.pgh.pa.us |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-bugs |
"Casey Duncan" <casey(at)pandora(dot)com> writes:
> CREATE FUNCTION write_error_trigf() RETURNS trigger AS '
> BEGIN
> RAISE EXCEPTION ''Writes not allowed to this table on this node'';
> END;
> ' LANGUAGE plpgsql;
> END; --Upgrade script
You did not show how this function is being used, but I'm wondering if
it is an AFTER trigger on inserts into ss? If so, the reason for the
out-of-memory failure might be accumulation of pending trigger event
records.
Without wishing to defend our lack of ability to spill trigger events
to disk, you probably wouldn't be happy with the performance if it did
work :-(. Consider making the trigger BEFORE instead of AFTER, so that
there's not a need to remember a ton of pending trigger firings. I don't
see any reason why this trigger needs to be AFTER.
regards, tom lane
From | Date | Subject | |
---|---|---|---|
Next Message | Lars Haugseth | 2006-05-10 12:54:41 | Re: BUG #2429: Explain does not report object's schema |
Previous Message | Cristiano Duarte | 2006-05-09 23:45:20 | Re: BUG #2429: Explain does not report object's schema |