diff --git a/src/Interpreters/InterpreterCreateQuery.cpp b/src/Interpreters/InterpreterCreateQuery.cpp index e054fe3c533e84280b5dcdd8c9075b1f848d9256..b238c48c0028be5bf58e2215a5d42655d105fcb0 100644 --- a/src/Interpreters/InterpreterCreateQuery.cpp +++ b/src/Interpreters/InterpreterCreateQuery.cpp @@ -401,7 +401,7 @@ InterpreterCreateQuery::TableProperties InterpreterCreateQuery::setProperties(AS if (create.columns_list->indices) for (const auto & index : create.columns_list->indices->children) properties.indices.push_back( - IndexDescription::getSkipIndexFromAST(index->clone(), properties.columns, context)); + IndexDescription::getIndexFromAST(index->clone(), properties.columns, context)); properties.constraints = getConstraintsDescription(create.columns_list->constraints); } diff --git a/src/Storages/AlterCommands.cpp b/src/Storages/AlterCommands.cpp index 4656d12362b54d066dc5c07847a5d34f00e666aa..eac4a5c29b52383c9d302b037eba66714c61a6b6 100644 --- a/src/Storages/AlterCommands.cpp +++ b/src/Storages/AlterCommands.cpp @@ -365,7 +365,7 @@ void AlterCommand::apply(StorageInMemoryMetadata & metadata, const Context & con ++insert_it; } - metadata.indices.emplace(insert_it, IndexDescription::getSkipIndexFromAST(index_decl, metadata.columns, context)); + metadata.indices.emplace(insert_it, IndexDescription::getIndexFromAST(index_decl, metadata.columns, context)); } else if (type == DROP_INDEX) { diff --git a/src/Storages/IndicesDescription.cpp b/src/Storages/IndicesDescription.cpp index ddc45345307a1642097fba9589ec4e087e63396e..357a407168da710d8943f776eb2e489cf65af507 100644 --- a/src/Storages/IndicesDescription.cpp +++ b/src/Storages/IndicesDescription.cpp @@ -20,7 +20,7 @@ namespace ErrorCodes }; -IndexDescription IndexDescription::getSkipIndexFromAST(const ASTPtr & definition_ast, const ColumnsDescription & columns, const Context & context) +IndexDescription IndexDescription::getIndexFromAST(const ASTPtr & definition_ast, const ColumnsDescription & columns, const Context & context) { const auto * index_definition = definition_ast->as(); if (!index_definition) @@ -103,7 +103,7 @@ IndicesDescription IndicesDescription::parse(const String & str, const ColumnsDe ASTPtr list = parseQuery(parser, str, 0, DBMS_DEFAULT_MAX_PARSER_DEPTH); for (const auto & index : list->children) - result.emplace_back(IndexDescription::getSkipIndexFromAST(index, columns, context)); + result.emplace_back(IndexDescription::getIndexFromAST(index, columns, context)); return result; } diff --git a/src/Storages/IndicesDescription.h b/src/Storages/IndicesDescription.h index 8398fb1b8cd6ce683bfe1894087498a57af639a8..f97215db96da26e9c615a285e0dabef01fb34538 100644 --- a/src/Storages/IndicesDescription.h +++ b/src/Storages/IndicesDescription.h @@ -47,7 +47,7 @@ struct IndexDescription size_t granularity; /// Parse index from definition AST - static IndexDescription getSkipIndexFromAST(const ASTPtr & definition_ast, const ColumnsDescription & columns, const Context & context); + static IndexDescription getIndexFromAST(const ASTPtr & definition_ast, const ColumnsDescription & columns, const Context & context); }; /// All non-primary indicies for storage diff --git a/src/Storages/MergeTree/registerStorageMergeTree.cpp b/src/Storages/MergeTree/registerStorageMergeTree.cpp index efe442e821ca43493f1c250d419db6f013f30174..26a02f8904cc8d0ccb13784f1f4b83fd19c09dec 100644 --- a/src/Storages/MergeTree/registerStorageMergeTree.cpp +++ b/src/Storages/MergeTree/registerStorageMergeTree.cpp @@ -607,7 +607,7 @@ static StoragePtr create(const StorageFactory::Arguments & args) if (args.query.columns_list && args.query.columns_list->indices) for (auto & index : args.query.columns_list->indices->children) - indices_description.push_back(IndexDescription::getSkipIndexFromAST(index, args.columns, args.context)); + indices_description.push_back(IndexDescription::getIndexFromAST(index, args.columns, args.context)); storage_settings->loadFromQuery(*args.storage_def);