Bug #109441 | "show tables like" slow without '%' when too many tables | ||
---|---|---|---|
Submitted: | 20 Dec 2022 21:14 | Modified: | 21 Dec 2022 18:01 |
Reporter: | Qiao Zhang | Email Updates: | |
Status: | Not a Bug | Impact on me: | |
Category: | MySQL Server | Severity: | S3 (Non-critical) |
Version: | 8 | OS: | Red Hat (7) |
Assigned to: | CPU Architecture: | x86 |
[20 Dec 2022 21:14]
Qiao Zhang
[21 Dec 2022 13:04]
MySQL Verification Team
Hi Mr. Zhang, Thank you for your bug report. However, we do not think that it is a bug. Simply, it is a border-line difference in the optimiser part of our server, which depends on many other factors like other queries running and similar. The choice in the optimiser search planning does not work 100 % precisely, so there are a few border-line cases, like the one that you describe .... It is also documented in our Reference Manual. Not a bug.
[21 Dec 2022 14:03]
Qiao Zhang
Thanks for your quick response. Do you have any suggestions to fix this issue? Since it is not a SQL and the objects are internal, I couldn't use hint to adjust the execution plan.
[21 Dec 2022 15:11]
MySQL Verification Team
Yes, of course ..... In your SELECT statement you can use IGNORE INDEX to make it go faster. This is explained in our Reference Manual that you can find on dev.mysql.com.
[21 Dec 2022 18:01]
Qiao Zhang
but IGNORE INDEX doesn't work for "show tables like" which is our problem.