You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@commons.apache.org by "Gary Gregory (JIRA)" <ji...@apache.org> on 2018/09/02 01:19:00 UTC

[jira] [Closed] (DBCP-521) dbcp 2.5.0 doesn't work with JDBC 3.0 drivers, e.g., jtds

     [ https://issues.apache.org/jira/browse/DBCP-521?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]

Gary Gregory closed DBCP-521.
-----------------------------
    Resolution: Duplicate

> dbcp 2.5.0 doesn't work with JDBC 3.0 drivers, e.g., jtds
> ---------------------------------------------------------
>
>                 Key: DBCP-521
>                 URL: https://issues.apache.org/jira/browse/DBCP-521
>             Project: Commons DBCP
>          Issue Type: Bug
>    Affects Versions: 2.5.0
>            Reporter: Bill Mitchell
>            Priority: Major
>
> Thanks to DBCP-508, to add the schema to the keys for the prepared statement cache, the Connection.getSchema() method is called.  On the dbcp side, this call is issued in a try-catch block that ignores a returned SQLException.  Unfortunately, at least one JDBC 3.0 driver, jdts 1.3.1, throws an AbstractMethodError in its getSchema method, as it doesn't support this.  (The 2.4.0 version of dbcp works fine with jtds.)
> At least two fixes are possible.  One could ignore any Throwable from getSchema call.  Or one could determine the major/minor JDBC version for the connection and issue the method call only on drivers that claim support for 4.1.  



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)