Bug #111987 | Error filesort result when max_length_for_sort_data is set to a big value | ||
---|---|---|---|
Submitted: | 7 Aug 2023 11:26 | Modified: | 8 Aug 2023 1:08 |
Reporter: | Zeng Zihao | Email Updates: | |
Status: | Can't repeat | Impact on me: | |
Category: | MySQL Server | Severity: | S3 (Non-critical) |
Version: | 5.7.42 | OS: | Any |
Assigned to: | CPU Architecture: | Any |
[7 Aug 2023 11:26]
Zeng Zihao
[7 Aug 2023 13:11]
MySQL Verification Team
Hi Mr. Zihao, Thank you for your bug report. However, we are unable to repeat your test case with 8.0. That variable is deprecated since 8.0.20 and is not used any more. Since 5.7 will be maintained only for the short time, it will get only the patches for the hard error. Since this variable is deprecated, this bug will not be fixed in 5.7. Please, start planning for the upgrade to 8.0. Not a bug.
[8 Aug 2023 1:08]
Zeng Zihao
This bug is related to the filesort algorithm. This SQL do not use the filesort in MySQL 8.0. Therefore, it does not have the bug. +----+-------------+------------+------------+------+---------------+------+---------+------+------+----------+-----------------+ | id | select_type | table | partitions | type | possible_keys | key | key_len | ref | rows | filtered | Extra | +----+-------------+------------+------------+------+---------------+------+---------+------+------+----------+-----------------+ | 1 | PRIMARY | <derived2> | NULL | ALL | NULL | NULL | NULL | NULL | 6775 | 100.00 | NULL | | 2 | DERIVED | t1 | NULL | ALL | NULL | NULL | NULL | NULL | 6775 | 100.00 | Using temporary | +----+-------------+------------+------------+------+---------------+------+---------+------+------+----------+-----------------+ In MySQL 5.7 +----+-------------+------------+------------+------+---------------+------+---------+------+------+----------+---------------------------------+ | id | select_type | table | partitions | type | possible_keys | key | key_len | ref | rows | filtered | Extra | +----+-------------+------------+------------+------+---------------+------+---------+------+------+----------+---------------------------------+ | 1 | PRIMARY | <derived2> | NULL | ALL | NULL | NULL | NULL | NULL | 6775 | 100.00 | NULL | | 2 | DERIVED | t1 | NULL | ALL | NULL | NULL | NULL | NULL | 6775 | 100.00 | Using temporary; Using filesort | +----+-------------+------------+------------+------+---------------+------+---------+------+------+----------+---------------------------------+
[8 Aug 2023 12:25]
MySQL Verification Team
Hi Mr. Zihao, Sorting is also using in some operations with temporary tables. Anyway, that variable is now deprecated.