Fix THERE_IS_NO_COLUMN for parallel replicas with constant table ALIAS#77307
Merged
KochetovNicolai merged 7 commits intomasterfrom Mar 11, 2025
Merged
Fix THERE_IS_NO_COLUMN for parallel replicas with constant table ALIAS#77307KochetovNicolai merged 7 commits intomasterfrom
KochetovNicolai merged 7 commits intomasterfrom
Conversation
Contributor
novikd
approved these changes
Mar 10, 2025
Member
novikd
left a comment
There was a problem hiding this comment.
LGTM. Not very obvious code, requires adding good comments.
| SET allow_experimental_parallel_reading_from_replicas = 1; | ||
| SET cluster_for_parallel_replicas = 'parallel_replicas'; | ||
| DROP TABLE IF EXISTS test_table; | ||
| CREATE TABLE test_table (a UInt64, b UInt64, c UInt64, d UInt64, x Array(String)) |
Member
There was a problem hiding this comment.
Let's also add a test with Nested.
Comment on lines
+678
to
+685
| if (column_node.hasExpression()) | ||
| { | ||
| auto expression = column_node.getExpression(); | ||
| if (expression->getNodeType() == QueryTreeNodeType::CONSTANT) | ||
| return visitConstant(expression); | ||
| else if (!use_column_identifier_as_action_node_name) | ||
| return visitImpl(expression); | ||
| } |
Member
There was a problem hiding this comment.
Please, add a comment with an explanation.
Member
|
The fuzzer of both this PR and now master is full of LOGICAL_ERRORS:
One stacktrace: @KochetovNicolai please have a look |
Member
|
Even more issues found -> #77558 Reverting |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):
Reverted
Fix the queries that read the ALIAS column from a table if the ALIAS expression is constant. Fix
THERE_IS_NO_COLUMNfor queries with parallel replicas enabled, andNumber of columns doesn't matchfor distributed queries.closes #76925
different fix for #77210