mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-25 00:52:02 +00:00
fix tests
This commit is contained in:
parent
666aab676e
commit
38e8bab6b1
@ -75,7 +75,7 @@ IMergingAlgorithm::Status FinishAggregatingInOrderAlgorithm::merge()
|
||||
auto & best_state = states[*best_input];
|
||||
best_state.to_row = states[*best_input].num_rows;
|
||||
|
||||
/// Find the positions upto which need to aggregate in other chunks.
|
||||
/// Find the positions up to which need to aggregate in other chunks.
|
||||
for (size_t i = 0; i < num_inputs; ++i)
|
||||
{
|
||||
if (!states[i].isValid() || i == *best_input)
|
||||
|
@ -13,13 +13,13 @@ using AggregatingTransformParamsPtr = std::shared_ptr<AggregatingTransformParams
|
||||
|
||||
/**
|
||||
* The second step of aggregation in order of sorting key.
|
||||
* The transform recieves k inputs with partialy aggregated data,
|
||||
* The transform receives k inputs with partially aggregated data,
|
||||
* sorted by group by key (prefix of sorting key).
|
||||
* Then it merges aggregated data from inputs by the following algorithm:
|
||||
* - At each step find the smallest value X of the sorting key among last rows of current blocks of inputs.
|
||||
* Since the data is sorted in order of sorting key and has no duplicates (because of aggregation),
|
||||
* X will never appear later in any of input streams.
|
||||
* - Aggregate all rows in current blocks of inputs upto the upper_bound of X using
|
||||
* - Aggregate all rows in current blocks of inputs up to the upper_bound of X using
|
||||
* regular hash table algorithm (Aggregator::mergeBlock).
|
||||
*/
|
||||
class FinishAggregatingInOrderAlgorithm final : public IMergingAlgorithm
|
||||
@ -47,7 +47,7 @@ private:
|
||||
/// Number of row starting from which need to aggregate.
|
||||
size_t current_row = 0;
|
||||
|
||||
/// Number of row upto which need to aggregate (not included).
|
||||
/// Number of row up to which need to aggregate (not included).
|
||||
size_t to_row = 0;
|
||||
|
||||
State(const Chunk & chunk, const SortDescription & description);
|
||||
|
@ -2,7 +2,7 @@
|
||||
ExpressionTransform
|
||||
(Aggregating)
|
||||
FinalizingSimpleTransform
|
||||
AggregatingSortedTransform 3 → 1
|
||||
FinishAggregatingInOrderTransform 3 → 1
|
||||
AggregatingInOrderTransform × 3
|
||||
(Expression)
|
||||
ExpressionTransform × 3
|
||||
|
Loading…
Reference in New Issue
Block a user