On Thu, Jul 08, 2004 at 04:52:04PM -0400, Rod Taylor wrote: > > create function crashme2() returns int strict language plpgsql as ' > > begin > > subbegin; > > select foo; -- aborts the transaction > > -- did not close the subxact > > end;'; > > I'm not sure I follow. Are you saying that the following code or > something similar will never work?
Right. The problem is that plpgsql stops executing code as soon as an error is found; the control returns to the main loop by way of a longjmp in the error reporting mechanism. I was quite dissappointed, as you will undoubtly be, when I found this out :-( Some sort of modification will be needed to the error processing mechanism, but this is beyond me at this point ... I don't have any idea how could this be. -- Alvaro Herrera (<alvherre[a]dcc.uchile.cl>) Licensee shall have no right to use the Licensed Software for productive or commercial use. (Licencia de StarOffice 6.0 beta) ---------------------------(end of broadcast)--------------------------- TIP 8: explain analyze is your friend