1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

Merge bk-internal.mysql.com:/home/bk/mysql-4.1

into narttu.mysql.fi:/my/mysql-4.1


sql/sql_select.cc:
  Auto merged
sql/unireg.cc:
  Auto merged
This commit is contained in:
unknown
2003-11-04 14:09:54 +02:00
3 changed files with 5 additions and 3 deletions

View File

@ -862,7 +862,8 @@ JOIN::optimize()
We only need to do this when we have a simple_order or simple_group
as in other cases the join is done before the sort.
*/
if ((order || group_list) && join_tab[const_tables].type != JT_ALL &&
if (const_tables != tables &&
(order || group_list) && join_tab[const_tables].type != JT_ALL &&
join_tab[const_tables].type != JT_FT &&
(order && simple_order || group_list && simple_group))
{