Re: JDBC feature request: auto savepoint per command

From: Mark Lewis <mark(dot)lewis(at)mir3(dot)com>
To: Michael Paesold <mpaesold(at)gmx(dot)at>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Oliver Jowett <oliver(at)opencloud(dot)com>, pgsql-jdbc(at)postgreSQL(dot)org
Subject: Re: JDBC feature request: auto savepoint per command
Date: 2007-04-24 13:55:29
Message-ID: 1177422929.20922.64.camel@archimedes
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-jdbc

On Tue, 2007-04-24 at 12:32 +0200, Michael Paesold wrote:
...
> If you look at the list archives, there were a number of people who did
> not expect this PostgreSQL-specific behavior (transaction rollback on
> statement error). I guess there will be many happy people if someone
> implements implicit savepoints in the JDBC driver.

I would be one of these happy people. I can say as a maintainer of a
large enterprise application which needs to support multiple databases
that our PostgreSQL port is by far the easiest to maintain, however
there are still a couple of pain points for us. One is the transaction
invalidation on any error, because we use complex transactions and rely
on the database referential integrity checks to enforce data
consistency. This combination means that if any RI check fails we need
to be able to re-try a possibly complex operation.

It's frustrating because all of the other DB's we support give you the
auto-savepoint before each statement semantics for free (instead of the
roughly 15% performance penalty mentioned last time the implicit
savepoint idea came up on the list). I guess this makes sense because
PG is the only database we support with O(1) rollback-- all of the other
databases need to do work to implement rollback anyway, so they already
have the infrastructure in place out of necessity.

Sorry about the rant, must be all the extra tension because I have
painful SQL Server and DB2 ports coming up that I'm already dreading :)

-- Mark

In response to

Browse pgsql-jdbc by date

  From Date Subject
Next Message Oilid Adsi 2007-04-24 14:19:53 Re: idle in transaction problem
Previous Message Dave Cramer 2007-04-24 12:37:42 Re: idle in transaction problem