mirror of
https://github.com/ClickHouse/ClickHouse.git
synced 2024-11-11 01:54:55 +00:00
Merge pull request #50242 from ClickHouse/fix-max-parallel-replicas-custom-key
Fix `02535_max_parallel_replicas_custom_key`
This commit is contained in:
commit
701e2fb6e3
@ -1192,13 +1192,14 @@ void Planner::buildPlanForQueryNode()
|
||||
|
||||
const auto & settings = query_context->getSettingsRef();
|
||||
|
||||
if (planner_context->getTableExpressionNodeToData().size() > 1
|
||||
&& (!settings.parallel_replicas_custom_key.value.empty() || settings.allow_experimental_parallel_reading_from_replicas > 0))
|
||||
/// Check support for JOIN for parallel replicas with custom key
|
||||
if (planner_context->getTableExpressionNodeToData().size() > 1)
|
||||
{
|
||||
if (settings.allow_experimental_parallel_reading_from_replicas == 1)
|
||||
if (settings.allow_experimental_parallel_reading_from_replicas == 1 || !settings.parallel_replicas_custom_key.value.empty())
|
||||
{
|
||||
LOG_WARNING(
|
||||
&Poco::Logger::get("Planner"), "JOINs are not supported with parallel replicas. Query will be executed without using them.");
|
||||
LOG_WARNING(
|
||||
&Poco::Logger::get("Planner"),
|
||||
"JOINs are not supported with parallel replicas. Query will be executed without using them.");
|
||||
|
||||
auto & mutable_context = planner_context->getMutableQueryContext();
|
||||
mutable_context->setSetting("allow_experimental_parallel_reading_from_replicas", Field(0));
|
||||
|
Loading…
Reference in New Issue
Block a user