mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-12-18 04:12:19 +00:00
Merge
This commit is contained in:
parent
2c067ad2c2
commit
80850909c7
@ -123,6 +123,8 @@ private:
|
|||||||
void executeDistinct( BlockInputStreams & streams, bool before_order, Names columns);
|
void executeDistinct( BlockInputStreams & streams, bool before_order, Names columns);
|
||||||
void executeSubqueriesInSetsAndJoins(BlockInputStreams & streams, SubqueriesForSets & subqueries_for_sets);
|
void executeSubqueriesInSetsAndJoins(BlockInputStreams & streams, SubqueriesForSets & subqueries_for_sets);
|
||||||
|
|
||||||
|
void ignoreWithTotals() { query.group_by_with_totals = false; }
|
||||||
|
|
||||||
ASTPtr query_ptr;
|
ASTPtr query_ptr;
|
||||||
ASTSelectQuery & query;
|
ASTSelectQuery & query;
|
||||||
Context context;
|
Context context;
|
||||||
|
@ -610,6 +610,8 @@ QueryProcessingStage::Enum InterpreterSelectQuery::executeFetchColumns(BlockInpu
|
|||||||
|
|
||||||
interpreter_subquery = new InterpreterSelectQuery(
|
interpreter_subquery = new InterpreterSelectQuery(
|
||||||
query.table, subquery_context, required_columns, QueryProcessingStage::Complete, subquery_depth + 1);
|
query.table, subquery_context, required_columns, QueryProcessingStage::Complete, subquery_depth + 1);
|
||||||
|
if (query_analyzer->hasAggregation())
|
||||||
|
interpreter_subquery->ignoreWithTotals();
|
||||||
}
|
}
|
||||||
|
|
||||||
/// если в настройках установлен default_sample != 1, то все запросы выполняем с сэмплингом
|
/// если в настройках установлен default_sample != 1, то все запросы выполняем с сэмплингом
|
||||||
|
@ -0,0 +1,4 @@
|
|||||||
|
1
|
||||||
|
0 0
|
||||||
|
|
||||||
|
0 0
|
@ -0,0 +1,2 @@
|
|||||||
|
SELECT count() FROM (SELECT dummy, sum(dummy) GROUP BY dummy WITH TOTALS);
|
||||||
|
SELECT * FROM (SELECT dummy, sum(dummy) GROUP BY dummy WITH TOTALS);
|
Loading…
Reference in New Issue
Block a user