On 18 February 2016 at 16:13, Vladimir Sitnikov <sitnikov.vladimir@xxxxxxxxx> wrote:
If you want to shoot yourself in a foot for fun and profit, you can
try https://github.com/pgjdbc/pgjdbc/pull/477.
I think this should be incorporated, once it's ready, as a non-default connection option. It's handy for porting applications.
I think PostgreSQL's behaviour is the most correct, but if people are porting apps and want to wear the performance impact of all those savepoints and have written their code to handle partially-failed xacts, then sure, they can have that.
I'm constantly astounded by how many people are willing to simply ignore errors and carry on with the transaction without even properly verifying that the error was the exact one they expected though. Seriously bad application development and it *will* bite them. The best, most correct thing to do remains to retry the whole transaction.