-
Notifications
You must be signed in to change notification settings - Fork 5.8k
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
The result of selecting with hexadecimal is wrong when character set utf8 #23507
Comments
This is likely just the issue that "new collation" ( select 'ǎ' collate utf8mb4_general_ci < 'ý' collate utf8mb4_general_ci;
-- returns 1 on MySQL 8.0.
-- returns 0 on TiDB nightly with old collation. The empty output is because CREATE TABLE `t1` (
`COL1` varchar(20) CHARACTER SET utf8 COLLATE utf8_general_ci NOT NULL,PRIMARY KEY (`COL1`(5)) USING BTREE
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = Dynamic;
insert into t1 values("ý");
insert into t1 values("ǎ");
select * from t1 where col1 between 0xC78E and 0xC3BD;
-- Not empty on MySQL 8
-- Empty on TiDB + old_collation |
Please edit this comment or add a new comment to complete the following informationNot a bug
Duplicate bug
BugNote: Make Sure that 'component', and 'severity' labels are added 1. Root Cause Analysis (RCA) (optional)2. Symptom (optional)3. All Trigger Conditions (optional)4. Workaround (optional)5. Affected versions6. Fixed versions |
mysql> SELECT VARIABLE_VALUE FROM mysql.tidb WHERE VARIABLE_NAME='new_collation_enabled';
+----------------+
| VARIABLE_VALUE |
+----------------+
| True |
+----------------+
1 row in set (0.08 sec)
|
what if you make the collation |
There is also this problem on collation utf8mb4_general_ci |
/assign |
it related to #23506. |
Please check whether the issue should be labeled with 'affects-x.y' or 'backport-x.y.z', |
Bug Report
Please answer these questions before submitting your issue. Thanks!
1. Minimal reproduce step (Required)
2. What did you expect to see? (Required)
3. What did you see instead (Required)
4. What is your TiDB version? (Required)
The text was updated successfully, but these errors were encountered: