call CloneAndLoadDataPart on database dest

This commit is contained in:
Guillaume Tassery 2019-09-17 08:12:27 +02:00
parent a47f0b1a60
commit 3ac8f52dd8

View File

@ -1202,7 +1202,7 @@ void StorageMergeTree::movePartitionTo(const StoragePtr & dest_table, const ASTP
MergeTreePartInfo dst_part_info(partition_id, temp_index, temp_index, src_part->info.level);
std::shared_lock<std::shared_mutex> part_lock(src_part->columns_lock);
dst_parts.emplace_back(cloneAndLoadDataPart(src_part, TMP_PREFIX, dst_part_info));
dst_parts.emplace_back(dest_table_storage->cloneAndLoadDataPart(src_part, TMP_PREFIX, dst_part_info));
}
/// ATTACH empty part set