Commit c00a5644 authored by unknown's avatar unknown

Merge mysql.com:/home/psergey/tmp_merge2

into  mysql.com:/home/psergey/mysql-5.1-merge6


mysql-test/r/rpl_user_variables.result:
  Auto merged
mysql-test/t/having.test:
  Auto merged
mysql-test/t/rpl_user_variables.test:
  Auto merged
sql/item_func.cc:
  Auto merged
sql/sql_lex.cc:
  Auto merged
sql/sql_lex.h:
  Auto merged
sql/sql_prepare.cc:
  Auto merged
sql/sql_select.cc:
  Auto merged
parents 704a69eb 47302570
......@@ -2087,19 +2087,20 @@ void reinit_stmt_before_use(THD *thd, LEX *lex)
sl->exclude_from_table_unique_test= FALSE;
/*
Copy WHERE, HAVING clause pointers to avoid damaging them by optimisation
Copy WHERE, HAVING clause pointers to avoid damaging them
by optimisation
*/
if (sl->prep_where)
{
sl->where= sl->prep_where->copy_andor_structure(thd);
sl->where->cleanup();
}
if (sl->prep_having)
{
sl->having= sl->prep_having->copy_andor_structure(thd);
sl->having->cleanup();
}
DBUG_ASSERT(sl->join == 0);
if (sl->prep_where)
{
sl->where= sl->prep_where->copy_andor_structure(thd);
sl->where->cleanup();
}
if (sl->prep_having)
{
sl->having= sl->prep_having->copy_andor_structure(thd);
sl->having->cleanup();
}
DBUG_ASSERT(sl->join == 0);
ORDER *order;
/* Fix GROUP list */
for (order= (ORDER *)sl->group_list.first; order; order= order->next)
......
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