StatementCreatorUtils always tries getParameterType on Oracle 12c driver

Issue: SPR-13825
This commit is contained in:
Juergen Hoeller 2015-12-29 11:19:21 +01:00
parent 1d8a3e1f07
commit e48ec4fcd3
1 changed files with 5 additions and 1 deletions

View File

@ -277,7 +277,11 @@ public abstract class StatementCreatorUtils {
if (jdbcDriverName == null) {
jdbcDriverName = dbmd.getDriverName();
}
if (checkGetParameterType) {
if (checkGetParameterType &&
!(jdbcDriverName.startsWith("Oracle") && dbmd.getDriverMajorVersion() >= 12)) {
// Register JDBC driver with no support for getParameterType, except for the
// Oracle 12c driver where getParameterType fails for specific statements only
// (so an exception thrown above does not indicate general lack of support).
driversWithNoSupportForGetParameterType.add(jdbcDriverName);
}
String databaseProductName = dbmd.getDatabaseProductName();