mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-23 08:02:02 +00:00
Store context created from projection analysis.
This commit is contained in:
parent
2892d447d4
commit
09325ff17e
@ -6118,6 +6118,7 @@ std::optional<ProjectionCandidate> MergeTreeData::getQueryProcessingStageWithAgg
|
||||
{
|
||||
ProjectionCandidate candidate{};
|
||||
candidate.desc = &projection;
|
||||
candidate.context = select.getContext();
|
||||
|
||||
auto sample_block = projection.sample_block;
|
||||
auto sample_block_for_keys = projection.sample_block_for_keys;
|
||||
|
@ -466,6 +466,7 @@ QueryPlanPtr MergeTreeDataSelectExecutor::read(
|
||||
fmt::format("MergeTree(with {} projection {})", query_info.projection->desc->type, query_info.projection->desc->name),
|
||||
query_info.storage_limits);
|
||||
plan->addStep(std::move(step));
|
||||
plan->addInterpreterContext(query_info.projection->context);
|
||||
return plan;
|
||||
}
|
||||
|
||||
|
@ -163,6 +163,9 @@ struct ProjectionCandidate
|
||||
SortDescription group_by_elements_order_descr;
|
||||
MergeTreeDataSelectAnalysisResultPtr merge_tree_projection_select_result_ptr;
|
||||
MergeTreeDataSelectAnalysisResultPtr merge_tree_normal_select_result_ptr;
|
||||
|
||||
/// Becasue projection analysis uses a separate interpreter.
|
||||
ContextPtr context;
|
||||
};
|
||||
|
||||
/** Query along with some additional data,
|
||||
|
Loading…
Reference in New Issue
Block a user