From: | Kris Jurka <books(at)ejurka(dot)com> |
---|---|
To: | Jim Gray <Jim(dot)Gray(at)Bull(dot)com> |
Cc: | "pgsql-jdbc(at)postgresql(dot)org" <pgsql-jdbc(at)postgresql(dot)org> |
Subject: | Re: Suspected JDBC bug |
Date: | 2014-06-28 00:38:16 |
Message-ID: | alpine.BSO.2.03.1406272035350.15771@ejurka.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-jdbc |
On Fri, 27 Jun 2014, Jim Gray wrote:
>
> I have a test case (attached) which has this output:
>
> Message: The column name pnum was not found in this ResultSet.
>
>
The PG JDBC driver requires you to select all primary key columns to be
able to update a ResultSet. The checking for this was not correct for
multicolumn primary keys and gave you the previous error message. With
the attached patch it will say:
Updating first result set value: E2 , with new value: E9
SQL Exception processing result set for: SELECT ?
SQLState: 24000
SQLCode: 0
Message: ResultSet is not updateable. The query that generated this
result set must select only one table, and must select all primary keys
from that table. See the JDBC 2.1 API Specification, section 5.6 for more
details.
Kris Jurka
Attachment | Content-Type | Size |
---|---|---|
check-updatable-primarykeys.patch | text/plain | 2.1 KB |
From | Date | Subject | |
---|---|---|---|
Next Message | keshava | 2014-07-01 07:43:38 | Postgres 9.3 JDBC issue with reading bytes |
Previous Message | Jim Gray | 2014-06-27 22:57:37 | Suspected JDBC bug |