mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-22 23:52:03 +00:00
Merge pull request #28366 from azat/remove-Temporary-part-fix-v2
Fix removing of parts in a Temporary state (v2 followup)
This commit is contained in:
commit
2c7a51d816
@ -1249,6 +1249,10 @@ void MergeTreeData::removePartsFinally(const MergeTreeData::DataPartsVector & pa
|
||||
/// TODO: use data_parts iterators instead of pointers
|
||||
for (const auto & part : parts)
|
||||
{
|
||||
/// Temporary does not present in data_parts_by_info.
|
||||
if (part->getState() == DataPartState::Temporary)
|
||||
continue;
|
||||
|
||||
auto it = data_parts_by_info.find(part->info);
|
||||
if (it == data_parts_by_info.end())
|
||||
throw Exception("Deleting data part " + part->name + " doesn't exist", ErrorCodes::LOGICAL_ERROR);
|
||||
|
Loading…
Reference in New Issue
Block a user