Compare commits

...

3 Commits

Author SHA1 Message Date
Nikolai Kochetov
4ffae801be Fixing another test. 2024-09-18 17:09:23 +00:00
Nikolai Kochetov
de30ec1d1d Fixing prewhere. 2024-09-18 16:51:18 +00:00
Nikolai Kochetov
79a62c99c5 Fixing style. 2024-09-18 16:39:58 +00:00
3 changed files with 13 additions and 4 deletions

View File

@ -200,7 +200,6 @@ void MultiplexedConnections::sendQuery(
}
void MultiplexedConnections::sendIgnoredPartUUIDs(const std::vector<UUID> & uuids)
{
std::lock_guard lock(cancel_mutex);

View File

@ -778,7 +778,18 @@ JoinTreeQueryPlan buildQueryPlanForTableExpression(QueryTreeNodePtr table_expres
auto & prewhere_info = table_expression_query_info.prewhere_info;
const auto & prewhere_actions = table_expression_data.getPrewhereFilterActions();
if (prewhere_actions)
std::vector<std::pair<FilterDAGInfo, std::string>> where_filters;
if (prewhere_actions && select_query_options.build_logical_plan)
{
where_filters.emplace_back(
FilterDAGInfo{
prewhere_actions->clone(),
prewhere_actions->getOutputs().at(0)->result_name,
true},
"Prewhere");
}
else if (prewhere_actions)
{
prewhere_info = std::make_shared<PrewhereInfo>();
prewhere_info->prewhere_actions = prewhere_actions->clone();
@ -791,7 +802,6 @@ JoinTreeQueryPlan buildQueryPlanForTableExpression(QueryTreeNodePtr table_expres
const auto & columns_names = table_expression_data.getColumnNames();
std::vector<std::pair<FilterDAGInfo, std::string>> where_filters;
const auto add_filter = [&](FilterDAGInfo & filter_info, std::string description)
{
bool is_final = table_expression_query_info.table_expression_modifiers

View File

@ -552,7 +552,7 @@ static QueryPlanResourceHolder replaceReadingFromTable(QueryPlan::Node & node, Q
{
SelectQueryOptions options(QueryProcessingStage::FetchColumns);
options.ignore_rename_columns = true;
InterpreterSelectQueryAnalyzer interpreter(wrapWithUnion(std::move(query)), context, options, column_names);
InterpreterSelectQueryAnalyzer interpreter(wrapWithUnion(std::move(query)), context, options);
reading_plan = std::move(interpreter).extractQueryPlan();
}
else