Search in sources :

Example 1 with SQLAlterTableItem

use of com.alibaba.druid.sql.ast.statement.SQLAlterTableItem in project Mycat-Server by MyCATApache.

the class MycatSchemaStatVisitor method visit.

@Override
public boolean visit(SQLAlterTableStatement x) {
    String tableName = x.getName().toString();
    TableStat stat = getTableStat(tableName, tableName);
    stat.incrementAlterCount();
    setCurrentTable(x, tableName);
    for (SQLAlterTableItem item : x.getItems()) {
        item.setParent(x);
        item.accept(this);
    }
    return false;
}
Also used : SQLAlterTableItem(com.alibaba.druid.sql.ast.statement.SQLAlterTableItem) TableStat(com.alibaba.druid.stat.TableStat)

Aggregations

SQLAlterTableItem (com.alibaba.druid.sql.ast.statement.SQLAlterTableItem)1 TableStat (com.alibaba.druid.stat.TableStat)1