merge 5.1 => 5.5

This commit is contained in:
Tor Didriksen 2013-02-07 17:08:59 +01:00
commit 84731d897c

View File

@ -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