mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
Bug #30393: Test "group_by" fails with a difference in "row count"
and strategy (explain) The fix for WL3527 adds tests that test if the index usage hints combinations don't cause syntax errors. The EXPLAIN for one of these tests can be affected by the size of the rowid on the disk (affected by the presence of large file support). Fixed to avoid the platform dependent test result by removing the irrelevant columns from the EXPLAIN result. mysql-test/r/group_by.result: Bug #30393: ignore columns irrelevant to the test mysql-test/t/group_by.test: Bug #30393: ignore columns irrelevant to the test
This commit is contained in:
@ -1129,7 +1129,7 @@ ERROR 42000: You have an error in your SQL syntax; check the manual that corresp
|
|||||||
EXPLAIN SELECT a FROM t1 USE INDEX FOR JOIN (i2)
|
EXPLAIN SELECT a FROM t1 USE INDEX FOR JOIN (i2)
|
||||||
USE INDEX FOR GROUP BY (i2) GROUP BY a;
|
USE INDEX FOR GROUP BY (i2) GROUP BY a;
|
||||||
id select_type table type possible_keys key key_len ref rows Extra
|
id select_type table type possible_keys key key_len ref rows Extra
|
||||||
1 SIMPLE t1 index NULL i2 9 NULL 144 Using index
|
1 SIMPLE t1 # NULL i2 # NULL # #
|
||||||
EXPLAIN SELECT a FROM t1 FORCE INDEX FOR JOIN (i2)
|
EXPLAIN SELECT a FROM t1 FORCE INDEX FOR JOIN (i2)
|
||||||
FORCE INDEX FOR GROUP BY (i2) GROUP BY a;
|
FORCE INDEX FOR GROUP BY (i2) GROUP BY a;
|
||||||
id select_type table type possible_keys key key_len ref rows Extra
|
id select_type table type possible_keys key key_len ref rows Extra
|
||||||
|
@ -828,6 +828,11 @@ EXPLAIN SELECT a FROM t1 USE INDEX (i2) USE INDEX ();
|
|||||||
EXPLAIN SELECT a FROM t1 FORCE INDEX ();
|
EXPLAIN SELECT a FROM t1 FORCE INDEX ();
|
||||||
--error ER_PARSE_ERROR
|
--error ER_PARSE_ERROR
|
||||||
EXPLAIN SELECT a FROM t1 IGNORE INDEX ();
|
EXPLAIN SELECT a FROM t1 IGNORE INDEX ();
|
||||||
|
# disable the columns irrelevant to this test here. On some systems
|
||||||
|
# without support for large files the rowid is shorter and its size affects
|
||||||
|
# the cost calculations. This causes the optimizer to choose loose index
|
||||||
|
# scan over normal index access.
|
||||||
|
--replace_column 4 # 7 # 9 # 10 #
|
||||||
EXPLAIN SELECT a FROM t1 USE INDEX FOR JOIN (i2)
|
EXPLAIN SELECT a FROM t1 USE INDEX FOR JOIN (i2)
|
||||||
USE INDEX FOR GROUP BY (i2) GROUP BY a;
|
USE INDEX FOR GROUP BY (i2) GROUP BY a;
|
||||||
EXPLAIN SELECT a FROM t1 FORCE INDEX FOR JOIN (i2)
|
EXPLAIN SELECT a FROM t1 FORCE INDEX FOR JOIN (i2)
|
||||||
|
Reference in New Issue
Block a user