From: | Dave Tenny <dave(dot)tenny(at)comcast(dot)net> |
---|---|
To: | pgsql-hackers(at)postgresql(dot)org |
Subject: | PostgreSQL JDBC driver Connection.setTransactionIsolation(Connection.TRANSACTION_SERIALIZABLE) failures |
Date: | 2003-08-05 22:35:32 |
Message-ID: | 3F303134.7050804@comcast.net |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers pgsql-jdbc |
I'm using 7.3.3 of the server, and pg73b1jdbc2.jar for the JDBC driver.
Various permutations of calls to the setTransactionIsolation all fail to
yield a driver state that will tell me that it is set up for
serializable transactions.
Help!?
I googled, I grepped. I find mention of problems with respect to JDBC
tests failing and patched, but see no reports of this as a bug,
or any fixes for it.
Here's the output from the attached program:
javac -classpath .:/usr/share/pgsql/pg73b1jdbc3.jar TxnIsolation.java &&
java -classpath .:/usr/share/pgsql/pg73b1jdbc3.jar TxnIsolation
supportsTransactions(): true
Default transaction isolation is 2
supportsTransactionIsolationLevel(Connection.TRANSACTION_READ_UNCOMMITTED):
false
supportsTransactionIsolationLevel(Connection.TRANSACTION_READ_COMMITTED):
true
supportsTransactionIsolationLevel(Connection.TRANSACTION_REPEATABLE_READ):
false
supportsTransactionIsolationLevel(Connection.TRANSACTION_SERIALIZABLE): true
Current transaction isolation is 2
Transaction isolation after setting to TRANSACTION_SERIALIZABLE is 2
^^^^^^^^^^^^^^^^^^^^ HAVE A PROBLEM ^^^^^^^^^^^^^^^^^^^^
Current auto commit is true
After settting auto commit to false, it is false
Transaction isolation after setAutoCommit() is 2
Current connection readonly status is false
Connection readonly after setting it to be readonly is true
---------------------------------------------------------------
Moving the setTransactionIsolation call to before the setAutoCommit
call also results in failure.
To run the program, you'll need to change the database and userid
parameters in the DriverManager.getConnection call to something that
works for you.
Attachment | Content-Type | Size |
---|---|---|
TxnIsolation.java | text/plain | 3.2 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | Tom Lane | 2003-08-05 22:38:52 | Re: logging stuff |
Previous Message | Neil Conway | 2003-08-05 22:27:48 | Re: Release changes |
From | Date | Subject | |
---|---|---|---|
Next Message | LEON | 2003-08-06 01:10:38 | Re: [SQL] JDBC encoding problem |
Previous Message | Philip A. Chapman | 2003-08-05 22:06:59 | [Fwd: Re: Connection.setCatalog method] |