mirror of
https://github.com/alibaba/druid.git
synced 2023-03-04 19:17:16 +00:00
refactor
This commit is contained in:
@@ -967,7 +967,7 @@ public class SQLASTOutputVisitor extends SQLASTVisitorAdapter {
|
||||
@Override
|
||||
public boolean visit(SQLTruncateStatement x) {
|
||||
print("TRUNCATE TABLE ");
|
||||
printAndAccept(x.getTableNames(), ", ");
|
||||
printAndAccept(x.getTableSources(), ", ");
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
@@ -377,7 +377,9 @@ public class SchemaStatVisitor extends SQLASTVisitorAdapter {
|
||||
|
||||
String originalTable = getCurrentTable();
|
||||
|
||||
for (SQLName name : x.getTableNames()) {
|
||||
for (SQLExprTableSource tableSource : x.getTableSources()) {
|
||||
SQLName name = (SQLName) tableSource.getExpr();
|
||||
|
||||
String ident = name.toString();
|
||||
setCurrentTable(ident);
|
||||
x.putAttribute("_old_local_", originalTable);
|
||||
|
||||
Reference in New Issue
Block a user