Bernt M. Johnsen wrote:
This behavior is not spec'd though currently for JDBC so the milage
might vary driver to driver. I have another outstanding issue in this
area to address so I will clean this up as part of that effort.
Daniel John Debrunner wrote (2005-05-02 09:23:59):
The JDBC tutorial (second edition) books says for this method
"Checks whether the database treats mixed ..."
note the *database*, not the driver. I think this method is describing
how identifiers behave in SQL statements, not in JDBC method calls.
Also section 26.1.5 of JDBC tutorial book (second edition) describes how
duplicate column names are handled, and it says if there are identical
names the application needs to use a column index to obtain the correct
value. Nothing about quoted names in JDBC method calls.
I admit I refferd to the tutorial (third ed.) not the spec.
That said, quoted and unquoted are not identical in SQL (unless the
quoted variant is all upper case and a legal SQL identifier, so "I", I
and i are identical while "i" is another identifier). I find it
reasonable to be able to access quoted identifires (e.g. "i") with the
column name too (e.q. like getInt("\"i\"")).