We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
mysql数据库支持KILL [CONNECTION | QUERY] processlist_id druid库解析必须要让sql带有CONNECTION 或QUERY,与mysql行为不符合
麻烦修改,谢谢 附带个人修改方案MySqlStatementParser.java :
@Override public SQLStatement parseKill() { accept(Token.KILL); MySqlKillStatement stmt = new MySqlKillStatement(); if (identifierEquals("CONNECTION")) { System.out.println(lexer.stringVal()); stmt.setType(MySqlKillStatement.Type.CONNECTION); lexer.nextToken(); } else if (identifierEquals("QUERY")) { stmt.setType(MySqlKillStatement.Type.QUERY); lexer.nextToken(); } else if (lexer.token() == Token.LITERAL_INT) { try { Long.parseLong(lexer.numberString()); // if no [QUERY|CONNECTION], the behavior is same as CONNECTION // by MYSQL 5.6.24 stmt.setType(MySqlKillStatement.Type.CONNECTION); } catch (Exception e) { throw new ParserException("not support kill " + lexer.numberString()); } } else { throw new ParserException("not support kill type " + lexer.token()); } SQLExpr threadId = this.exprParser.expr(); stmt.setThreadId(threadId); return stmt; }
The text was updated successfully, but these errors were encountered:
improved mysql parser Kill_Statement support. issue #1326
11ff35f
已完整支持,请等待下一个版本1.0.23发布吧
Sorry, something went wrong.
No branches or pull requests
mysql数据库支持KILL [CONNECTION | QUERY] processlist_id
druid库解析必须要让sql带有CONNECTION 或QUERY,与mysql行为不符合
麻烦修改,谢谢
附带个人修改方案MySqlStatementParser.java :
The text was updated successfully, but these errors were encountered: