mirror of
https://github.com/MariaDB/server.git
synced 2026-01-06 05:22:24 +03:00
fixed st_select_lex initialization
fixed mustiupdate subselect compatibility (bug 217)
This commit is contained in:
@@ -400,6 +400,7 @@ int mysql_multi_update(THD *thd,
|
||||
table_list->grant.want_privilege=(SELECT_ACL & ~table_list->grant.privilege);
|
||||
if ((res=open_and_lock_tables(thd,table_list)))
|
||||
DBUG_RETURN(res);
|
||||
fix_tables_pointers(thd->lex.all_selects_list);
|
||||
|
||||
thd->select_limit=HA_POS_ERROR;
|
||||
if (setup_fields(thd, 0, table_list, *fields, 1, 0, 0))
|
||||
@@ -408,7 +409,7 @@ int mysql_multi_update(THD *thd,
|
||||
/*
|
||||
Count tables and setup timestamp handling
|
||||
*/
|
||||
for (tl= (TABLE_LIST*) table_list ; tl ; tl=tl->next)
|
||||
for (tl= select_lex->get_table_list() ; tl ; tl=tl->next)
|
||||
{
|
||||
TABLE *table= tl->table;
|
||||
if (table->timestamp_field)
|
||||
@@ -426,7 +427,8 @@ int mysql_multi_update(THD *thd,
|
||||
|
||||
List<Item> total_list;
|
||||
res= mysql_select(thd, &select_lex->ref_pointer_array,
|
||||
table_list, select_lex->with_wild, total_list,
|
||||
select_lex->get_table_list(), select_lex->with_wild,
|
||||
total_list,
|
||||
conds, 0, (ORDER *) NULL, (ORDER *)NULL, (Item *) NULL,
|
||||
(ORDER *)NULL,
|
||||
options | SELECT_NO_JOIN_CACHE | SELECT_NO_UNLOCK,
|
||||
|
||||
Reference in New Issue
Block a user