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

can't find column while use index merge #25045

Closed
aytrack opened this issue Jun 2, 2021 · 3 comments · Fixed by #25294
Closed

can't find column while use index merge #25045

aytrack opened this issue Jun 2, 2021 · 3 comments · Fixed by #25294
Assignees
Labels
severity/major sig/planner SIG: Planner type/bug The issue is confirmed as a bug.

Comments

@aytrack
Copy link
Contributor

aytrack commented Jun 2, 2021

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

create table t1(a int primary key, b int, c int, key(b), key(c));
explain select /*+ use_index_merge(t1) */ * from t1 where c=10 or (b=10 and a=10);

2. What did you expect to see? (Required)

execute successfully

3. What did you see instead (Required)

MySQL root@127.0.0.1:test> explain select /*+ use_index_merge(t1) */ * from t1 where c=10 or (b=10 and a=10);
(1105, "Can't find column test.t1.b in schema Column: [test.t1.a] Unique key: []")

4. What is your TiDB version? (Required)

MySQL root@127.0.0.1:test> select tidb_version()\G
***************************[ 1. row ]***************************
tidb_version() | Release Version: v5.1.0-alpha-87-g0158f71cd
Edition: Community
Git Commit Hash: 0158f71cda6ccbbd382c6e8759904234baca259c
Git Branch: HEAD
UTC Build Time: 2021-06-01 11:51:39
GoVersion: go1.16.4
Race Enabled: false
TiKV Min Version: v3.0.0-60965b006877ca7234adaced7890d7b029ed1306
Check Table Before Drop: false
@aytrack aytrack added type/bug The issue is confirmed as a bug. sig/planner SIG: Planner severity/major labels Jun 2, 2021
@zhuo-zhi
Copy link
Contributor

zhuo-zhi commented Jun 2, 2021

/assign

@ti-srebot
Copy link
Contributor

Please edit this comment or add a new comment to complete the following information

Not a bug

  1. Remove the 'type/bug' label
  2. Add notes to indicate why it is not a bug

Duplicate bug

  1. Add the 'type/duplicate' label
  2. Add the link to the original bug

Bug

Note: Make Sure that 'component', and 'severity' labels are added
Example for how to fill out the template: #20100

1. Root Cause Analysis (RCA) (optional)

2. Symptom (optional)

3. All Trigger Conditions (optional)

4. Workaround (optional)

5. Affected versions

6. Fixed versions

@vivid392845427
Copy link

@zhuo-zhi ,please check pick 5.0

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
severity/major sig/planner SIG: Planner type/bug The issue is confirmed as a bug.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants