If they are defined, they can override table-level settings.
return std::nullopt;
    /
    if (settings.allow_experimental_query_deduplication)
        return std::nullopt;
    /
    if (select_query->arrayJoinExpressionList().first)
        return std::nullopt;
    /
    /
    /
    if (select_query->join())
        return std::nullopt;
    /
    if (select_query->interpolate() && !select_query->interpolate()->children.empty())
        return std::nullopt;
    auto query_options = SelectQueryOptions(
        QueryProcessingStage::WithMergeableState,
        / 1,
        / true
    ).ignoreProjections().ignoreAlias();
    InterpreterSelectQuery select(
        query_ptr,
        query_context,
        query_options,
        std::move(query_info.subquery_for_sets),
        std::move(query_info.sets));
    const auto & analysis_result = select.getAnalysisResult();
    query_info.sets = std::move(select.getQueryAnalyzer()->getPreparedSets());
    query_info.subquery_for_sets = std::move(select.getQueryAnalyzer()->getSubqueriesForSets());
    bool can_use_aggregate_projection = true;