Re: "A block containing an EXCEPTION clause is significantly more expensive to enter and exit than a block without one" - Mailing list pgsql-general

From Christophe Pettus
Subject Re: "A block containing an EXCEPTION clause is significantly more expensive to enter and exit than a block without one"
Date
Msg-id D1837AA1-ADF0-4236-8BEC-08A1357A77AE@thebuild.com
Whole thread Raw
In response to Re: "A block containing an EXCEPTION clause is significantly more expensive to enter and exit than a block without one"  (Pavel Stehule <pavel.stehule@gmail.com>)
Responses Re: "A block containing an EXCEPTION clause is significantly more expensive to enter and exit than a block without one"
List pgsql-general

> On Jun 12, 2022, at 23:07, Pavel Stehule <pavel.stehule@gmail.com> wrote:
> The lazy implementation theoretically can be possible, but why?

Isn't one of the reasons for the savepoint (in fact, the principal reason) to reset the connection back to non-error
stateso that execution can continue?  In that case, it really does need to create the savepoint at the start of the
block,regardless of what's in it, since any statement can raise an error. 


pgsql-general by date:

Previous
From: Tom Lane
Date:
Subject: Re: "A block containing an EXCEPTION clause is significantly more expensive to enter and exit than a block without one"
Next
From: Joel Rabinovitch
Date:
Subject: Tools to convert timestamp data to another time zone in PostgreSQL