diff options
author | unknown <monty@work.mysql.com> | 2001-09-18 21:27:28 +0200 |
---|---|---|
committer | unknown <monty@work.mysql.com> | 2001-09-18 21:27:28 +0200 |
commit | a5e44471ed7d0187b0ace078d3cf828859ad8958 (patch) | |
tree | 0ba2643f27699a78ea6e727f5a3a1b7cf14885f7 /sql | |
parent | e154b30a57cc119f8e47936f23a261324228662f (diff) | |
parent | c66208cfbf2726a2c9fe6eed9f4d71e2fff5dfbd (diff) | |
download | mariadb-git-a5e44471ed7d0187b0ace078d3cf828859ad8958.tar.gz |
merge
Docs/manual.texi:
Auto merged
myisam/mi_check.c:
Auto merged
Diffstat (limited to 'sql')
-rw-r--r-- | sql/sql_select.cc | 14 |
1 files changed, 8 insertions, 6 deletions
diff --git a/sql/sql_select.cc b/sql/sql_select.cc index 3ae337c47ed..108f6aca1f2 100644 --- a/sql/sql_select.cc +++ b/sql/sql_select.cc @@ -570,8 +570,9 @@ mysql_select(THD *thd,TABLE_LIST *tables,List<Item> &fields,COND *conds, if (!(select_options & SELECT_BIG_RESULT) && ((group && join.const_tables != join.tables && - !test_if_skip_sort_order(&join.join_tab[join.const_tables], group, - thd->select_limit,0)) || + (!simple_group || + !test_if_skip_sort_order(&join.join_tab[join.const_tables], group, + thd->select_limit,0))) || select_distinct) && join.tmp_table_param.quick_group && !procedure) { @@ -584,10 +585,11 @@ mysql_select(THD *thd,TABLE_LIST *tables,List<Item> &fields,COND *conds, order=group; if (order && (join.const_tables == join.tables || - test_if_skip_sort_order(&join.join_tab[join.const_tables], order, - (join.const_tables != join.tables - 1 || - (join.select_options & OPTION_FOUND_ROWS)) ? - HA_POS_ERROR : thd->select_limit,0))) + (simple_order && + test_if_skip_sort_order(&join.join_tab[join.const_tables], order, + (join.const_tables != join.tables - 1 || + (join.select_options & OPTION_FOUND_ROWS)) ? + HA_POS_ERROR : thd->select_limit,0)))) order=0; select_describe(&join,need_tmp, (order != 0 && |