Re: Call for 7.5 feature completion

Matt Miller <mattm@epx.com>

From: Matt Miller <mattm@epx.com>
To: Nicholas Walker <nick@walkerdatanet.com>
Cc: Dennis Bjorklund <db@zigo.dhs.org>, Josh Berkus <josh@agliodbs.com>, pgsql-hackers@postgresql.org, Rod Taylor <pg@rbt.ca>, Alvaro Herrera <alvherre@alvh.no-ip.org>, Bruce Momjian <pgman@candle.pha.pa.us>
Date: 2005-08-26T17:39:26Z
Lists: pgsql-hackers
On Fri, 2005-08-26 at 13:13 -0400, Nicholas Walker wrote:
> >You can't use savepoints, you can trap errors which is implemented using 
> >savepoints. You still might want to write code like this:
> >
> >BEGIN
> >
> >....
> >
> >SAVEPOINT foo;
> >
> >....
> >
> >IF SOME_ERROR_CODE = 1234 THEN
> >   ROLLBACK TO SAVEPOINT foo;
> >END
> >
> >...
> I agree, and I think savepoints would be much more usefull if you could 
> call them from pl/pgsql...

Maybe if PL/pgSQL had user-defined exceptions then the language's
identity of savepoints and exception blocks would be a little easier to
work with.  Is anything happening with the patch for user-defined
exceptions, posted at
http://archives.postgresql.org/pgsql-patches/2005-06/msg00475.php (and
also discussed elsewhere)?