On Thu, 16 Sep 2004, Tom Lane wrote:
Quote:
Hmm, how are you issuing these commands exactly (what protocol message
sequence is being sent?). |
I've made the test case and the development version of the jar file
available here if you're interested: http://www.ejurka.com/pgsql/jars/tgl/
Here is the relevent section of the log file:
<=BE ReadyForQuery(T)
simple execute,
handler=org.postgresql.jdbc2.AbstractJdbc2Statemen t$StatementResultHandler@133796,
maxRows=0, fetchSize=0, flags=5
FE=> Parse(stmt=null,query="INSERT INTO savepointtable VALUES
($1)",oids={23})
FE=> Bind(stmt=null,portal=null,$1=<1>)
FE=> Describe(portal=null)
FE=> Execute(portal=null,limit=1)
FE=> Sync
<=BE ParseComplete [null]
<=BE BindComplete [null]
<=BE NoData
<=BE CommandStatus(INSERT 66384 1)
<=BE ReadyForQuery(T)
simple execute,
handler=org.postgresql.jdbc2.AbstractJdbc2Statemen t$StatementResultHandler@4741d6,
maxRows=0, fetchSize=0, flags=5
FE=> Parse(stmt=null,query="SAVEPOINT JDBC_SAVEPOINT_0",oids={})
FE=> Bind(stmt=null,portal=null)
FE=> Describe(portal=null)
FE=> Execute(portal=null,limit=1)
FE=> Sync
<=BE ParseComplete [null]
<=BE BindComplete [null]
<=BE NoData
<=BE CommandStatus(SAVEPOINT)
<=BE ReadyForQuery(T)
simple execute,
handler=org.postgresql.jdbc2.AbstractJdbc2Statemen t$StatementResultHandler@337d0f,
maxRows=0, fetchSize=0, flags=5
FE=> Parse(stmt=null,query="INSERT INTO savepointtable VALUES
($1)",oids={23})
FE=> Bind(stmt=null,portal=null,$1=<1>)
FE=> Describe(portal=null)
FE=> Execute(portal=null,limit=1)
FE=> Sync
<=BE ParseComplete [null]
<=BE BindComplete [null]
<=BE NoData
<=BE ErrorMessage(ERROR: duplicate key violates unique constraint
"savepointtable_pkey"
Location: File: nbtinsert.c, Routine: _bt_check_unique, Line: 255
ServerSQLState: 23505)
java.sql.SQLException: ERROR: duplicate key violates unique constraint
"savepointtable_pkey"
Location: File: nbtinsert.c, Routine: _bt_check_unique, Line: 255
ServerSQLState: 23505
at
org.postgresql.core.v3.QueryExecutorImpl.receiveEr rorResponse(QueryExecutorImpl.java:1141)
at
org.postgresql.core.v3.QueryExecutorImpl.processRe sults(QueryExecutorImpl.java:944)
at
org.postgresql.core.v3.QueryExecutorImpl.execute(Q ueryExecutorImpl.java:139)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.execut e(AbstractJdbc2Statement.java:346)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.execut eWithFlags(AbstractJdbc2Statement.java:294)
at
org.postgresql.jdbc2.AbstractJdbc2Statement.execut eUpdate(AbstractJdbc2Statement.java:249)
at SavepointTest.addRow(SavepointTest.java:8)
at SavepointTest.main(SavepointTest.java:25)
SQLException: SQLState(23505)
<=BE ReadyForQuery(E)
simple execute,
handler=org.postgresql.jdbc2.AbstractJdbc2Statemen t$StatementResultHandler@1e4cbc4,
maxRows=0, fetchSize=0, flags=23
FE=> Parse(stmt=null,query="ROLLBACK TO SAVEPOINT
JDBC_SAVEPOINT_0",oids={})
FE=> Bind(stmt=null,portal=null)
FE=> Execute(portal=null,limit=1)
FE=> Sync
FE=> Terminate
org.postgresql.util.PSQLException: An I/O error occured while sending to
the backend
Kris Jurka
---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?
http://archives.postgresql.org