From 45ffec6c5cd698e3ae0dd058bd1c7ff0b9a27b72 Mon Sep 17 00:00:00 2001 From: Nikolai Kochetov Date: Thu, 18 Apr 2019 19:27:10 +0300 Subject: [PATCH] Fix Cube transform. --- dbms/src/Processors/Transforms/CubeTransform.cpp | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/dbms/src/Processors/Transforms/CubeTransform.cpp b/dbms/src/Processors/Transforms/CubeTransform.cpp index 1207805b3e1..1f8d2e4105c 100644 --- a/dbms/src/Processors/Transforms/CubeTransform.cpp +++ b/dbms/src/Processors/Transforms/CubeTransform.cpp @@ -39,6 +39,7 @@ Chunk CubeTransform::generate() if (mask) { --mask; + consumed_chunk = gen_chunk; auto columns = current_columns; for (size_t i = 0; i < keys.size(); ++i) @@ -49,7 +50,7 @@ Chunk CubeTransform::generate() auto cube_block = params->aggregator.mergeBlocks(cube_blocks, false); auto num_rows = cube_block.rows(); - consumed_chunk = Chunk(cube_block.getColumns(), num_rows); + gen_chunk = Chunk(cube_block.getColumns(), num_rows); } finalizeChunk(gen_chunk);