Repository navigation
Fix 01660_join_or_any - #75262
Merged
Merged
Fix 01660_join_or_any#75262
Conversation
Contributor
|
This is an automated comment for commit b878331 with description of existing statuses. It's updated for the latest CI running ❌ Click here to open a full report in a separate page
Successful checks
|
novikd
approved these changes
Jan 30, 2025
vdimir
enabled auto-merge
February 5, 2025 18:44
nihalzp
pushed a commit
to nihalzp/ClickHouse
that referenced
this pull request
Oct 9, 2026
…across parallel replicas With `any_join_distinct_right_table_keys = 1`, `ANY RIGHT JOIN` becomes kind `Right` with strictness `RightAny`: each left row takes the first right row of its key, and the whole key is marked used. That choice is made over ALL right rows of the key. The leftmost-leaf gate `allowParallelReplicasForJoinTree` admitted every `RIGHT` join, so the whole join was shipped to the replicas, each replica read only its coordinated share of the right table, and a left row that matched on several replicas was emitted once per replica (`01660_join_or_any` returned `6 4` twice in the new ParallelReplicas job). The plan-based pass had the same gap: `liftSplitAboveJoin` lifted the right-side split above such a join. The query-tree walk `getSupportingParallelReplicasQueries` already refuses this shape (ClickHouse#75262). Make the leftmost-leaf gate refuse it too, and in plan-based mode refuse only the lift, so the right read stays distributed below the join and the join runs once over all right rows. Co-Authored-By: Claude Opus 5.5 <[email protected]>
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):
Close #74641
Documentation entry for user-facing changes
CI Settings (Only check the boxes if you know what you are doing)
All builds in Builds_1 and Builds_2 stages are always mandatory and will run independently of the checks below: