mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-21 23:21:59 +00:00
Merge pull request #15293 from amosbird/bc3
Replace useless multiset with unordered_set
This commit is contained in:
commit
bc662ac4e0
@ -223,7 +223,7 @@ Pipe MergeTreeDataSelectExecutor::readFromParts(
|
||||
if (part_column_queried)
|
||||
VirtualColumnUtils::filterBlockWithQuery(query_info.query, virtual_columns_block, context);
|
||||
|
||||
std::multiset<String> part_values = VirtualColumnUtils::extractSingleValueFromBlock<String>(virtual_columns_block, "_part");
|
||||
auto part_values = VirtualColumnUtils::extractSingleValueFromBlock<String>(virtual_columns_block, "_part");
|
||||
|
||||
metadata_snapshot->check(real_column_names, data.getVirtuals(), data.getStorageID());
|
||||
|
||||
|
@ -1,6 +1,6 @@
|
||||
#pragma once
|
||||
|
||||
#include <set>
|
||||
#include <unordered_set>
|
||||
|
||||
#include <Core/Block.h>
|
||||
#include <Parsers/IAST_fwd.h>
|
||||
@ -30,9 +30,9 @@ void filterBlockWithQuery(const ASTPtr & query, Block & block, const Context & c
|
||||
|
||||
/// Extract from the input stream a set of `name` column values
|
||||
template <typename T>
|
||||
std::multiset<T> extractSingleValueFromBlock(const Block & block, const String & name)
|
||||
auto extractSingleValueFromBlock(const Block & block, const String & name)
|
||||
{
|
||||
std::multiset<T> res;
|
||||
std::unordered_set<T> res;
|
||||
const ColumnWithTypeAndName & data = block.getByName(name);
|
||||
size_t rows = block.rows();
|
||||
for (size_t i = 0; i < rows; ++i)
|
||||
|
Loading…
Reference in New Issue
Block a user