Using liquibase-2.0-rc5 the method OracleTypeConverter.convertToDatabaseTypeString(Column, Database) which is implemented by class AbstractTypeConverter does not handle the following Oracle specific types:
- NVARCHAR2
- BINARY_DOUBLE
- BINARY_FLOAT
Our workaround is a class derived from OracleTypeConverter which implements convertToDatabaseTypeString the following way:
@Override
public String convertToDatabaseTypeString(Column referenceColumn,
Database database) {
String translatedTypeName = referenceColumn.getTypeName();
if (“NVARCHAR2”.equals(translatedTypeName)) {
translatedTypeName = translatedTypeName
+ “(” + referenceColumn.getColumnSize() + “)”;
} else if (“BINARY_FLOAT”.equals(translatedTypeName)
|| “BINARY_DOUBLE”.equals(translatedTypeName)) {
// nothing to do
} else {
translatedTypeName = super.convertToDatabaseTypeString(
referenceColumn, database);
}
return translatedTypeName;
}
Probably it would be better to handle these cases in the OracleTypeConverter itself.