diff --git a/src/Storages/MergeTree/ReplicatedMergeTreeQueue.cpp b/src/Storages/MergeTree/ReplicatedMergeTreeQueue.cpp index 8661b2aa784..7d8018e7577 100644 --- a/src/Storages/MergeTree/ReplicatedMergeTreeQueue.cpp +++ b/src/Storages/MergeTree/ReplicatedMergeTreeQueue.cpp @@ -1963,7 +1963,7 @@ MutationCommands ReplicatedMergeTreeQueue::MutationsSnapshot::getAlterMutationCo NameSet ReplicatedMergeTreeQueue::MutationsSnapshot::getAllUpdatedColumns() const { - if (!params.need_data_mutations) + if (!hasDataMutations()) return {}; NameSet res; diff --git a/src/Storages/StorageMergeTree.cpp b/src/Storages/StorageMergeTree.cpp index 4d0aef53ff1..8bab73c3db7 100644 --- a/src/Storages/StorageMergeTree.cpp +++ b/src/Storages/StorageMergeTree.cpp @@ -2468,7 +2468,7 @@ MutationCommands StorageMergeTree::MutationsSnapshot::getAlterMutationCommandsFo NameSet StorageMergeTree::MutationsSnapshot::getAllUpdatedColumns() const { - if (!params.need_data_mutations) + if (!hasDataMutations()) return {}; NameSet res; @@ -2492,7 +2492,7 @@ MergeTreeData::MutationsSnapshotPtr StorageMergeTree::getMutationsSnapshot(const auto res = std::make_shared(params, std::move(info)); - bool need_data_mutations = res->params.need_data_mutations && num_data_mutations_to_apply > 0; + bool need_data_mutations = res->hasDataMutations(); bool need_metadata_mutations = num_metadata_mutations_to_apply > 0; if (!need_data_mutations && !need_metadata_mutations)