On Mon, Sep 21, 2009 at 12:06 PM, Alvaro Herrera
<alvhe...@commandprompt.com> wrote:
> David Fetter escribió:
>
>> Taken literally, that would mean, "the last action before the backend
>> exits," but at least to me, that sounds troubling for the same reasons
>> that "end of transaction" triggers do.  What happens when there are
>> two different END blocks in a session?
>
> The manual is clear that both are executed.
>
>> With connection poolers, backends can last quite awhile.  Is it OK for
>> the END block to run hours after the rest of the code?
>
> This is an interesting point -- should END blocks be called on DISCARD ALL?

It seems pretty reasonable that it would.  The intention of DISCARD
ALL is to completely reset the entire session.

...Robert

-- 
Sent via pgsql-bugs mailing list (pgsql-bugs@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-bugs

Reply via email to