Details
-
Bug
-
Resolution: Unresolved
-
Major
-
None
-
13.0.11.Final
-
None
-
-
Documentation (Ref Guide, User Guide, etc.)
Description
I've been followed the Infinispan documentation
When I tried to create a persistence cache with table-jdbc-store with Oracle database I´ve got an exception: "SqlType not supported: 1". The table have a column typed as char.
I' have looked the code, and class:
package org.infinispan.persistence.sql; public abstract class AbstractSchemaJdbcStore
Maybe I found a bug in the method:
protected static ProtostreamFieldType from(int sqlType) { switch (sqlType) { case Types.INTEGER: return INT_32; case Types.BIGINT: return INT_64; case Types.FLOAT: case Types.REAL: return FLOAT; case Types.DOUBLE: case Types.NUMERIC: case Types.DECIMAL: return DOUBLE; case Types.BIT: case Types.BOOLEAN: return BOOL; case Types.VARCHAR: case Types.NVARCHAR: case Types.LONGVARCHAR: case Types.LONGNVARCHAR: return STRING; case Types.BLOB: case Types.BINARY: case Types.VARBINARY: case Types.LONGVARBINARY: return BYTES; case Types.DATE: case Types.TIMESTAMP: case Types.TIMESTAMP_WITH_TIMEZONE: return DATE; default: throw new IllegalArgumentException("SqlType not supported: " + sqlType); } }
when it tries a type.char so it throws a new exception. And the SQL Type not supported It's a char type.