From: | QuanZongliang <quanzongliang(at)hotmail(dot)com> |
---|---|
To: | Gary Greenberg <gary(at)icontrol(dot)com> |
Cc: | <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: Error while retrieving generated keys |
Date: | 2007-03-09 04:48:08 |
Message-ID: | BAY106-W2067CB520F9E75A8FB33AAB5780@phx.gbl |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc pgsql-odbc |
from AbstractJdbc3Connection.java:
348 public PreparedStatement prepareStatement(String sql, int autoGeneratedKeys)349 throws SQLException350 {351 if (autoGeneratedKeys != Statement.NO_GENERATED_KEYS)352 throw new PSQLException(GT.tr("Returning autogenerated keys is not supported."), PSQLState.NOT_IMPLEMENTED);353 return prepareStatement(sql);354 }So, it is not supported.Only the prepareStatement(sql, Statement.NO_GENERATED_KEYS) can be used.
From: gary(at)icontrol(dot)comTo: pgsql-jdbc(at)postgresql(dot)orgSubject: [JDBC] Error while retrieving generated keysDate: Thu, 8 Mar 2007 19:49:52 -0800
My application trew the following exception:
org.postgresql.util.PSQLException: Returning autogenerated keys is not supported.
at org.postgresql.jdbc3.AbstractJdbc3Connection.prepareStatement(AbstractJdbc3Connection.java:352)
at org.apache.commons.dbcp.DelegatingConnection.prepareStatement(DelegatingConnection.java:394)
at org.apache.commons.dbcp.PoolingDataSource$PoolGuardConnectionWrapper.prepareStatement(PoolingDataSource.java:370)
I am using 8.2-504.jdbc3 driver with the PostgreSql 8.0.8 on SUSE Linux.
I have not seen anywhere in the documentation that this standard JDBC3 feature is not supported.
Can anyone explain it to me, please.
From | Date | Subject | |
---|---|---|---|
Next Message | Dave Cramer | 2007-03-09 12:00:55 | Re: Error while retrieving generated keys |
Previous Message | Gary Greenberg | 2007-03-09 03:49:52 | Error while retrieving generated keys |
From | Date | Subject | |
---|---|---|---|
Next Message | noreply | 2007-03-09 15:07:58 | [ psqlodbc-Bugs-1002503 ] ODBC Failure |
Previous Message | noreply | 2007-03-09 01:07:43 | [ psqlodbc-Bugs-1002503 ] ODBC Failure |