mysql parser bug fixed

This commit is contained in:
温少
2012-05-17 14:06:42 +08:00
34 changed files with 526 additions and 117 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;
}