Current specdiffs for JDBC 4.2
Douglas Surber
douglas.surber at oracle.com
Mon Jan 7 08:35:56 PST 2013
+1
At 11:59 PM 12/21/2012, Mark Rotteveel wrote:
>On 19-12-2012 15:43, Lance Andersen - Oracle wrote:
>>>>http://cr.openjdk.java.net/~lancea/8005080/specdiffs.00/java/sql/CallableStatement-report.html#method:registerOutParameter(int,%20java.sql.SQLType)
>>>>(and other methods accepting java.sql.SQLType)
>>>>
>>>>I think it is unfortunate that there are no methods accepting the
>>>>java.sql.JDBCType enum directly (as an enum); it makes - as a
>>>>driver implementer - only supporting the basic enum a bit more
>>>>cumbersome.
>>
>>If a JDBCType such as JDBCTYPES.INTEGER is passed you can still use
>>as an enum
>>
>>We had lengthy discussions on this in 2010 and early 2011 on this
>>and it was felt that passing an enum was too restrictive.
>
>Now that I have thought some more on it, I agree. Even if there was
>also a method just accepting the enum, it wouldn't make it easier in
>the driver implementation.
>
>I think adding a method to JDBCTypes to lookup the enum by
>java.sql.Types value would be a great addition, as it would simplify
>conversion from java.sql.Types to JDBCTypes. Lets say
>JDBCTypes.valueOf(int sqlType), similar to JDBCTypes.valueOf(String
>name).
>
>Mark
>--
>Mark Rotteveel
More information about the jdbc-spec-discuss
mailing list