#1937 - When add a new col with @DbComment in Entity,the DbMigration does not generate comment ddl

This commit is contained in:
rob bygrave
2020-02-17 14:19:19 +13:00
parent cbaaad89ab
commit 171d1a19f4
2 changed files with 20 additions and 0 deletions
@@ -951,6 +951,10 @@ public class BaseTableDdl implements TableDdl {
}
platformDdl.alterTableAddColumn(buffer, tableName, column, onHistoryTable, help.getDefaultValue());
final String comment = column.getComment();
if (comment != null && !comment.isEmpty()) {
platformDdl.addColumnComment(buffer, tableName, column.getName(), comment);
}
if (!onHistoryTable) {
help.writeAfter(buffer);