Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

plan: use Column.UniqueID in conditionChecker of ranger (#8236) #9587

Merged
merged 2 commits into from
Mar 7, 2019

Conversation

XuHuaiyu
Copy link
Contributor

@XuHuaiyu XuHuaiyu commented Mar 7, 2019

cherry-pick #8236

@XuHuaiyu XuHuaiyu added type/bug-fix This PR fixes a bug. sig/planner SIG: Planner type/2.1 cherry-pick labels Mar 7, 2019
@XuHuaiyu
Copy link
Contributor Author

XuHuaiyu commented Mar 7, 2019

/run-all-tests tidb-test=release-2.1 tikv=release-2.1 pd=release-2.1

c.Assert(fmt.Sprintf("%s", conds), Equals, tt.accessConds, Commentf("wrong access conditions for expr: %s", tt.exprStr))
result, err := ranger.BuildColumnRange(conds, new(stmtctx.StatementContext), col.RetType)
c.Assert(err, IsNil)
got := fmt.Sprintf("%v", result)
c.Assert(got, Equals, tt.resultStr, Commentf("different for expr %s, col: %v", tt.exprStr, col))
}
}

func (s *testRangerSuite) TestIndexRangeElimininatedProjection(c *C) {
Copy link
Contributor

Choose a reason for hiding this comment

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

We should remove this test case, since 2.1 does not have optimization to simplify ifnull() expression, so this test would fail.

Copy link
Member

Choose a reason for hiding this comment

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

How about keeping the test and modifying the test expect result?

@XuHuaiyu
Copy link
Contributor Author

XuHuaiyu commented Mar 7, 2019

/run-all-tests tidb-test=release-2.1 tikv=release-2.1 pd=release-2.1

Copy link
Contributor

@eurekaka eurekaka left a comment

Choose a reason for hiding this comment

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

LGTM

@eurekaka eurekaka added the status/LGT1 Indicates that a PR has LGTM 1. label Mar 7, 2019
Copy link
Member

@zz-jason zz-jason left a comment

Choose a reason for hiding this comment

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

LGTM

@zz-jason zz-jason merged commit bc42d7f into pingcap:release-2.1 Mar 7, 2019
@zz-jason zz-jason added status/LGT2 Indicates that a PR has LGTM 2. and removed status/LGT1 Indicates that a PR has LGTM 1. labels Mar 7, 2019
@XuHuaiyu XuHuaiyu deleted the kn branch April 22, 2019 09:35
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sig/planner SIG: Planner status/LGT2 Indicates that a PR has LGTM 2. type/bug-fix This PR fixes a bug.
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants