mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
bug fixed for SchemaStatVisitor
This commit is contained in:
@@ -903,6 +903,13 @@ public class SchemaStatVisitor extends SQLASTVisitorAdapter {
|
||||
if (subQueryMap.containsKey(currentTable)) {
|
||||
return false;
|
||||
}
|
||||
|
||||
if (x.getParent() instanceof SQLAggregateExpr) {
|
||||
SQLAggregateExpr aggregateExpr = (SQLAggregateExpr) x.getParent();
|
||||
if ("count".equalsIgnoreCase(aggregateExpr.getMethodName())) {
|
||||
return false;
|
||||
}
|
||||
}
|
||||
|
||||
if (currentTable != null) {
|
||||
Column column = addColumn(currentTable, "*");
|
||||
|
||||
@@ -327,6 +327,7 @@ public class WebStatFilter extends AbstractWebStatImpl implements Filter {
|
||||
this.status = statusCode;
|
||||
}
|
||||
|
||||
@SuppressWarnings("deprecation")
|
||||
public void setStatus(int statusCode, String statusMessage) {
|
||||
super.setStatus(statusCode, statusMessage);
|
||||
this.status = statusCode;
|
||||
|
||||
Reference in New Issue
Block a user