Conversation
(cherry picked from commit 723256e1ea9759e42959950ef67f7ea5143fcc43)
(cherry picked from commit 84f0d53dc612083e55a3ee28fdd55e2b3f0197f5)
Fix incorrect createColumn call on join clause "changed" flag in system.settings is calculated incorrectly for settings with multiple values EXPLAIN actions for JOIN step Setting JoinAlgorithm respect specified order Move setting `join_algorithm` to compat settings * fixes ut * better join step name * fixes stateless test * fixes stateless test - 2 --------- Co-authored-by: Alexey Milovidov <[email protected]> Co-authored-by: alesapin <[email protected]> Co-authored-by: vdimir <[email protected]> Co-authored-by: Robert Schulze <[email protected]> (cherry picked from commit fb43370909bdb911e8479556a0e2c045dc01cf89)
(cherry picked from commit 729cc33f9af38db875a9b46960b733a3f85a21c9)
(cherry picked from commit 2e5809ee54e73ccff614e14c78f42e19782d7a7d)
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: f9dbcf6504
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
| if (JoinPtr direct_kv_join = tryKeyValueJoin(analyzed_join, right_sample_block)) | ||
| { | ||
| /// Do not need to execute plan for right part, it's ready. | ||
| joined_plan.reset(); | ||
| return direct_kv_join; |
There was a problem hiding this comment.
Avoid returning DirectKeyValueJoin for streaming joins
In streaming plans (joined_plan->isStreaming()), the pipeline uses Streaming::JoinStep, which unconditionally treats the join as an IHashJoin (it does std::dynamic_pointer_cast<IHashJoin>(join) when building the output header and JoinTransform state). The new direct-key-value branch here can return DirectKeyValueJoin, which is not an IHashJoin. That makes the cast null and will crash or miscompute the header/transform when a streaming join hits a key-value right side with join_algorithm including direct (or default). This path didn’t exist before because streaming joins never returned DirectKeyValueJoin. Either guard against direct key‑value joins in streaming mode or teach Streaming::JoinStep/JoinTransform to handle non‑hash joins.
Useful? React with 👍 / 👎.
PR checklist:
proton: starts/endsfor new code in existing community code base ?Please write user-readable short description of the changes: