diff --git a/src/Interpreters/ActionsDAG.cpp b/src/Interpreters/ActionsDAG.cpp index d5e1f332b50..3dc855b93ff 100644 --- a/src/Interpreters/ActionsDAG.cpp +++ b/src/Interpreters/ActionsDAG.cpp @@ -1194,7 +1194,7 @@ ActionsDAGPtr ActionsDAG::merge(ActionsDAG && first, ActionsDAG && second) if (it == first_result.end() || it->second.empty()) { if (first.project_input) - throw Exception(ErrorCodes::LOGICAL_ERROR, + throw Exception(ErrorCodes::UNKNOWN_IDENTIFIER, "Cannot find column {} in ActionsDAG result", input_node->result_name); first.inputs.push_back(input_node);