diff --git a/src/Common/PoolWithFailoverBase.h b/src/Common/PoolWithFailoverBase.h index f8789e3c827..3ce7be4b3c5 100644 --- a/src/Common/PoolWithFailoverBase.h +++ b/src/Common/PoolWithFailoverBase.h @@ -65,7 +65,7 @@ public: , log(log_) { if (nested_pools.empty()) - throw DB::Exception(DB::ErrorCodes::LOGICAL_ERROR, "Cannot create PoolWithFailover cause nested pools are empty"); + throw DB::Exception(DB::ErrorCodes::ALL_CONNECTION_TRIES_FAILED, "Cannot create PoolWithFailover cause nested pools are empty"); for (size_t i = 0;i < nested_pools.size(); ++i) shared_pool_states[i].config_priority = nested_pools[i]->getPriority();