mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 08:02:02 +00:00
dbms: probably better [#CONV-2944].
This commit is contained in:
parent
e3f8671dd6
commit
e54ee51124
@ -501,6 +501,7 @@ Block Aggregator::convertToBlock(AggregatedDataVariants & data_variants)
|
||||
AggregatedDataWithUInt64Key & data = data_variants.key64;
|
||||
|
||||
IColumn & first_column = *key_columns[0];
|
||||
first_column.reserve(data.size() + with_totals);
|
||||
|
||||
size_t j = with_totals ? 1 : 0;
|
||||
for (AggregatedDataWithUInt64Key::const_iterator it = data.begin(); it != data.end(); ++it, ++j)
|
||||
@ -515,6 +516,7 @@ Block Aggregator::convertToBlock(AggregatedDataVariants & data_variants)
|
||||
{
|
||||
AggregatedDataWithStringKey & data = data_variants.key_string;
|
||||
IColumn & first_column = *key_columns[0];
|
||||
first_column.reserve(data.size() + with_totals);
|
||||
|
||||
size_t j = with_totals ? 1 : 0;
|
||||
for (AggregatedDataWithStringKey::const_iterator it = data.begin(); it != data.end(); ++it, ++j)
|
||||
@ -529,6 +531,9 @@ Block Aggregator::convertToBlock(AggregatedDataVariants & data_variants)
|
||||
{
|
||||
AggregatedDataWithKeys128 & data = data_variants.keys128;
|
||||
|
||||
for (size_t i = 0; i < keys_size; ++i)
|
||||
key_columns[i]->reserve(data.size() + with_totals);
|
||||
|
||||
size_t j = with_totals ? 1 : 0;
|
||||
for (AggregatedDataWithKeys128::const_iterator it = data.begin(); it != data.end(); ++it, ++j)
|
||||
{
|
||||
@ -548,6 +553,9 @@ Block Aggregator::convertToBlock(AggregatedDataVariants & data_variants)
|
||||
{
|
||||
AggregatedDataHashed & data = data_variants.hashed;
|
||||
|
||||
for (size_t i = 0; i < keys_size; ++i)
|
||||
key_columns[i]->reserve(data.size() + with_totals);
|
||||
|
||||
size_t j = with_totals ? 1 : 0;
|
||||
for (AggregatedDataHashed::const_iterator it = data.begin(); it != data.end(); ++it, ++j)
|
||||
{
|
||||
|
Loading…
Reference in New Issue
Block a user