Re: Feature discussion: Should syntax errors abort a transaction? - Mailing list pgsql-general

From Greg Sabino Mullane
Subject Re: Feature discussion: Should syntax errors abort a transaction?
Date
Msg-id fb632c3877658162ade7d7ec050d0636@biglumber.com
Whole thread Raw
In response to Feature discussion: Should syntax errors abort a transaction?  (Craig Ringer <craig@postnewspapers.com.au>)
List pgsql-general
-----BEGIN PGP SIGNED MESSAGE-----
Hash: RIPEMD160


...
> ON_ERROR_ROLLBACK=interactive provides a helper for that in psql.
>
> Savepoints are overhead, though, and I don't understand why they're
> required for statements that don't even parse.

Other have handled the latter part of the above already (short version:
error is the only sane response to a non-parsing statement), but as
to the first part, the overhead is really not that high. Yes, psql
will create and remove a savepoint around each statement, but this is
a very lightweight action, especially if you are using psql in
interactive mode. In other words, we already have an elegant and
lightweight approach to the described problem.


- --
Greg Sabino Mullane greg@turnstep.com
End Point Corporation http://www.endpoint.com/
PGP Key: 0x14964AC8 201206191146
http://biglumber.com/x/web?pk=2529DF6AB8F79407E94445B4BC9B906714964AC8
-----BEGIN PGP SIGNATURE-----

iEYEAREDAAYFAk/gn30ACgkQvJuQZxSWSsgekgCfcoBq2VjCitjrpK9CrSMFob0Y
YF8An3Qp/OQjAcRsEBahE5OIbFzEEZX/
=hHAn
-----END PGP SIGNATURE-----



pgsql-general by date:

Previous
From: Edson Richter
Date:
Subject: Re: Feature discussion: Should syntax errors abort a transaction?
Next
From: Mark Rostron
Date:
Subject: db server processes hanging around