Commit 8d8b5ab5 authored by Tor Didriksen's avatar Tor Didriksen

merge 5.1 => 5.5

parents 656cf87c 134e2480
......@@ -13931,7 +13931,8 @@ test_if_skip_sort_order(JOIN_TAB *tab,ORDER *order,ha_rows select_limit,
if (best_key >= 0)
{
if (table->quick_keys.is_set(best_key) && best_key != ref_key)
if (select &&
table->quick_keys.is_set(best_key) && best_key != ref_key)
{
key_map map;
map.clear_all(); // Force the creation of quick select
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment