Skip to content

Commit

Permalink
0006017: DDL Create Table Oracle with varchar columns that have a size >
Browse files Browse the repository at this point in the history
4000
  • Loading branch information
joshahicks committed Oct 12, 2023
1 parent f6b4dfd commit ace9fff
Showing 1 changed file with 5 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -587,8 +587,12 @@ protected void processChange(Database currentModel, Database desiredModel,
@Override
public String getSqlType(Column column) {
if (column.getMappedTypeCode() == Types.VARCHAR && column.getSizeAsInt() > 4000) {
column.setSize("4000");
return "VARCHAR(4000)";
}
if (column.getMappedTypeCode() == Types.CHAR && column.getSizeAsInt() > 2000) {
return "CHAR(2000)";
}

PlatformColumn platformColumn = column.findPlatformColumn(databaseName);
if (platformColumn != null && platformColumn.getType() != null) {
if (platformColumn.getType().equals(ROWID_TYPE)) {
Expand Down Expand Up @@ -619,6 +623,5 @@ protected void writeCascadeAttributesForForeignKeyDelete(ForeignKey key, StringB
super.writeCascadeAttributesForForeignKeyDelete(key, ddl);
}
}


}

0 comments on commit ace9fff

Please sign in to comment.