From 97dee1f7cf38637c968201d6a4755d642a99b014 Mon Sep 17 00:00:00 2001 From: Zhengguo Yang Date: Thu, 10 Sep 2020 09:55:19 +0800 Subject: [PATCH] [Bug] Fix enable feature error (#4558) Fix enable feature may failed, because of base index pass to alter table. --- .../main/java/org/apache/doris/analysis/AlterTableStmt.java | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/fe/fe-core/src/main/java/org/apache/doris/analysis/AlterTableStmt.java b/fe/fe-core/src/main/java/org/apache/doris/analysis/AlterTableStmt.java index f95dd27b5a..c2779f5cba 100644 --- a/fe/fe-core/src/main/java/org/apache/doris/analysis/AlterTableStmt.java +++ b/fe/fe-core/src/main/java/org/apache/doris/analysis/AlterTableStmt.java @@ -87,7 +87,7 @@ public class AlterTableStmt extends DdlStmt { // has rollup table if (table.getVisibleIndex().size() > 1) { for (MaterializedIndex idx : table.getVisibleIndex()) { - // add a column to rollup index it will add to base table automaticlly, + // add a column to rollup index it will add to base table automatically, // if add a column here it will duplicated if (idx.getId() == table.getBaseIndexId()) { continue; @@ -100,7 +100,7 @@ public class AlterTableStmt extends DdlStmt { } else { // no rollup tables AddColumnClause addColumnClause = new AddColumnClause(ColumnDef.newDeleteSignColumnDef(), null, - table.getIndexNameById(table.getBaseIndexId()), null); + null, null); addColumnClause.analyze(analyzer); clauses.add(addColumnClause); }