diff options
author | unknown <igor@olga.mysql.com> | 2007-06-23 23:33:55 -0700 |
---|---|---|
committer | unknown <igor@olga.mysql.com> | 2007-06-23 23:33:55 -0700 |
commit | e009b764b930a6b3b0ae95b6c828944c6c83b130 (patch) | |
tree | ae0541b020ffe5109738509ac86b90e660a3b213 /sql-common | |
parent | f3940ebaf03b828a07edcde97f72b768ad803e3d (diff) | |
download | mariadb-git-e009b764b930a6b3b0ae95b6c828944c6c83b130.tar.gz |
Fixed bug #25602. A query with DISTINCT in the select list to which
the loose scan optimization for grouping queries was applied returned
a wrong result set when the query was used with the SQL_BIG_RESULT
option.
The SQL_BIG_RESULT option forces to use sorting algorithm for grouping
queries instead of employing a suitable index. The current loose scan
optimization is applied only for one table queries when the suitable
index is covering. It does not make sense to use sort algorithm in this
case. However the create_sort_index function does not take into account
the possible choice of the loose scan to implement the DISTINCT operator
which makes sorting unnecessary. Moreover the current implementation of
the loose scan for queries with distinct assumes that sorting will
never happen. Thus in this case create_sort_index should not call
the function filesort.
mysql-test/r/group_min_max.result:
Added a test case for bug #25602.
mysql-test/t/group_min_max.test:
Added a test case for bug #25602.
Diffstat (limited to 'sql-common')
0 files changed, 0 insertions, 0 deletions