bug fixed for sql parser

This commit is contained in:
温少
2012-03-09 09:51:10 +08:00
parent 74316fba51
commit 786859fc71
13 changed files with 164 additions and 26 deletions
@@ -217,6 +217,7 @@ public class SQLExprParser extends SQLParser {
case SCHEMA:
case AT:
case COLUMN:
case IF:
sqlExpr = new SQLIdentifierExpr(lexer.stringVal());
lexer.nextToken();
break;
@@ -1090,10 +1091,6 @@ public class SQLExprParser extends SQLParser {
SQLCharactorDataType charType = new SQLCharactorDataType(dataType.getName());
charType.getArguments().addAll(dataType.getArguments());
if (lexer.token() != Token.IDENTIFIER) {
throw new ParserException("syntax error " + lexer.token() + " " + lexer.stringVal());
}
if (identifierEquals("CHARACTER")) {
lexer.nextToken();