Skip to content

[fix](Nereids)plan translator lost other conjuncts on hash join node#12391

Merged
924060929 merged 3 commits intoapache:masterfrom
morrySnow:fix_other_condition
Sep 7, 2022
Merged

[fix](Nereids)plan translator lost other conjuncts on hash join node#12391
924060929 merged 3 commits intoapache:masterfrom
morrySnow:fix_other_condition

Conversation

@morrySnow
Copy link
Copy Markdown
Contributor

@morrySnow morrySnow commented Sep 6, 2022

Proposed changes

Problem summary

In the earlier PR #11812 , we split join condition into two parts: hash join conjuncts and other condition. But we forgot to translate other condition into other conjuncts in HashJoinNode of legacy planner. So we get wrong result if query has other condition on join node. Such as:

SELECT * FROM lineorder INNER JOIN part ON lo_partkey = p_partkey WHERE lo_orderkey > p_size;

Checklist(Required)

  1. Does it affect the original behavior:
    • Yes
    • No
    • I don't know
  2. Has unit tests been added:
    • Yes
    • No
    • No Need
  3. Has document been added or modified:
    • Yes
    • No
    • No Need
  4. Does it need to update dependencies:
    • Yes
    • No
  5. Are there any changes that cannot be rolled back:
    • Yes (If Yes, please explain WHY)
    • No

Further comments

If this is a relatively large or complex change, kick off the discussion at dev@doris.apache.org by explaining why you chose the solution you did and what alternatives you considered, etc...

@Kikyou1997
Copy link
Copy Markdown
Contributor

LGTM

924060929
924060929 previously approved these changes Sep 6, 2022
jackwener
jackwener previously approved these changes Sep 6, 2022
Copy link
Copy Markdown
Member

@jackwener jackwener left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@github-actions github-actions bot added the approved Indicates a PR has been approved by one committer. label Sep 6, 2022
@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Sep 6, 2022

PR approved by at least one committer and no changes requested.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Sep 6, 2022

PR approved by anyone and no changes requested.

@morrySnow morrySnow dismissed stale reviews from jackwener and 924060929 via 8b0241e September 6, 2022 16:17
@github-actions github-actions bot added the area/planner Issues or PRs related to the query planner label Sep 7, 2022
@924060929 924060929 merged commit 46776af into apache:master Sep 7, 2022
@morrySnow morrySnow deleted the fix_other_condition branch September 7, 2022 03:32
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

approved Indicates a PR has been approved by one committer. area/nereids area/planner Issues or PRs related to the query planner kind/test reviewed

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants