improved db2 parser. for issue #2548

This commit is contained in:
wenshao
2018-05-05 16:59:55 +08:00
parent 7de08da610
commit 802ada35dd
6 changed files with 96 additions and 16 deletions
@@ -3817,13 +3817,22 @@ public class SQLASTOutputVisitor extends SQLASTVisitorAdapter implements Paramet
if (x.isSetNotNull()) { // postgresql
print0(ucase ? " SET NOT NULL" : " set not null");
}
if (x.isDropNotNull()) { // postgresql
print0(ucase ? " DROP NOT NULL" : " drop not null");
}
if (x.getSetDefault() != null) { // postgresql
print0(ucase ? " SET DEFAULT " : " set default ");
x.getSetDefault().accept(this);
}
final SQLDataType dataType = x.getDataType();
if (dataType != null) {
print0(ucase ? " SET DATA TYPE " : " set data type ");
dataType.accept(this);
}
if (x.isDropDefault()) { // postgresql
print0(ucase ? " DROP DEFAULT" : " drop default");
}