summaryrefslogtreecommitdiff
path: root/sql/sql_select.cc
diff options
context:
space:
mode:
authorunknown <igor@olga.mysql.com>2008-01-11 10:05:34 -0800
committerunknown <igor@olga.mysql.com>2008-01-11 10:05:34 -0800
commitd8363a408ffd345c45f2cd9e9427a986e56c08eb (patch)
tree452ad4047ebe0b5ea6fe58c769ecdbb0ca5fc044 /sql/sql_select.cc
parent34cae15606134da46ed426d4ac42f01c93992324 (diff)
downloadmariadb-git-d8363a408ffd345c45f2cd9e9427a986e56c08eb.tar.gz
Fixed bug #33697.
When the function test_if_skip_sort_order prefers index backward scan to ref access the corresponding access functions must be set accordingly. mysql-test/include/mix1.inc: Added a test case for bug #33697. Corrected one previous bad merge. mysql-test/r/innodb_mysql.result: Added a test case for bug #33697. mysql-test/t/disabled.def: Turned innodb_mysql test on.
Diffstat (limited to 'sql/sql_select.cc')
-rw-r--r--sql/sql_select.cc3
1 files changed, 2 insertions, 1 deletions
diff --git a/sql/sql_select.cc b/sql/sql_select.cc
index 741e8afec1d..741132d2b9c 100644
--- a/sql/sql_select.cc
+++ b/sql/sql_select.cc
@@ -13123,7 +13123,8 @@ check_reverse_order:
select->quick=tmp;
}
}
- else if (tab->ref.key >= 0 && tab->ref.key_parts <= used_key_parts)
+ else if (tab->type != JT_NEXT &&
+ tab->ref.key >= 0 && tab->ref.key_parts <= used_key_parts)
{
/*
SELECT * FROM t1 WHERE a=1 ORDER BY a DESC,b DESC