pingcap/tidb

"show status like" is not case insensitive

Open

#26.253 geöffnet am 14. Juli 2021

Auf GitHub ansehen
 (3 Kommentare) (2 Reaktionen) (0 zugewiesene Personen)Go (6.186 Forks)batch import
help wantedseverity/minorsig/sql-infratype/bug

Repository-Metriken

Stars
 (40.090 Stars)
PR-Merge-Metriken
 (Durchschn. Merge 14T 4h) (346 gemergte PRs in 30 T)

Beschreibung

Bug Report

Please answer these questions before submitting your issue. Thanks!

1. Minimal reproduce step (Required)

show status like 'ssl_cipher';

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

mysql> show status like 'ssl_cipher';

+---------------+-------+
| Variable_name | Value |
+---------------+-------+
| Ssl_cipher    |       |
+---------------+-------+
1 row in set (0,00 sec)

3. What did you see instead (Required)

tidb> show status like 'ssl_cipher';

Empty set (0,00 sec)

show status like 'Ssl_chipher'; works.

4. What is your TiDB version? (Required)

tidb_version(): Release Version: v5.2.0-alpha-272-g88cbdecc5
Edition: Community
Git Commit Hash: 88cbdecc58437619a0dd1c5554be20d079971978
Git Branch: master
UTC Build Time: 2021-07-14 13:23:50
GoVersion: go1.16.2
Race Enabled: false
TiKV Min Version: v3.0.0-60965b006877ca7234adaced7890d7b029ed1306
Check Table Before Drop: false

MySQL has case insensitive match for LIKE of status and variables, where TiDB seems to have case sensitive matching of LIKE operator. I also tried with both options for:

tidb> SELECT VARIABLE_VALUE FROM mysql.tidb WHERE VARIABLE_NAME='new_collation_enabled';

+----------------+
| VARIABLE_VALUE |
+----------------+
| True           |
+----------------+
1 row in set (0,00 sec)

Contributor Guide