Skip to content

Wrong enum calculation result in where condition. #22717

Closed
@wshwsh12

Description

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

drop table t;
create table t(e enum('a','','b'));
insert into t values(1),(2),(3);
select * from t where e;

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

MySQL [test]> select * from t where e;
+------+
| e    |
+------+
| a    |
|      |
| b    |
+------+
3 rows in set (0.000 sec)

3. What did you see instead (Required)

[tidb]> select * from t where e;
+------+
| e    |
+------+
| a    |
| b    |
+------+
2 rows in set (0.001 sec)

4. What is your TiDB version? (Required)

17a65ab

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions