mysql parser bug fixed

This commit is contained in:
温少
2012-05-17 14:47:54 +08:00
37 changed files with 767 additions and 156 deletions
@@ -797,7 +797,26 @@ public class SQLASTOutputVisitor extends SQLASTVisitorAdapter {
println();
print(x.getOperator().name);
println();
x.getRight().accept(this);
boolean needParen = false;
if (x.getOrderBy() != null) {
needParen = true;
}
if (needParen) {
print('(');
x.getRight().accept(this);
print(')');
} else {
x.getRight().accept(this);
}
if (x.getOrderBy() != null) {
println();
x.getOrderBy().accept(this);
}
return false;
}