mirror of
https://github.com/MariaDB/server.git
synced 2026-05-09 16:44:29 +02:00
Merge epotemkin@bk-internal.mysql.com:/home/bk/mysql-5.0-opt
into moonbone.local:/mnt/gentoo64/work/25122-bug-5.0-opt-mysql sql/mysql_priv.h: Auto merged sql/sql_base.cc: Auto merged sql/sql_delete.cc: Auto merged sql/sql_insert.cc: Auto merged sql/sql_load.cc: Auto merged sql/sql_parse.cc: Auto merged sql/sql_update.cc: Auto merged
This commit is contained in:
commit
b72e3110da
7 changed files with 19 additions and 13 deletions
|
|
@ -640,7 +640,7 @@ bool mysql_prepare_update(THD *thd, TABLE_LIST *table_list,
|
|||
/* Check that we are not using table that we are updating in a sub select */
|
||||
{
|
||||
TABLE_LIST *duplicate;
|
||||
if ((duplicate= unique_table(thd, table_list, table_list->next_global)))
|
||||
if ((duplicate= unique_table(thd, table_list, table_list->next_global, 0)))
|
||||
{
|
||||
update_non_unique_table_error(table_list, "UPDATE", duplicate);
|
||||
my_error(ER_UPDATE_TABLE_USED, MYF(0), table_list->table_name);
|
||||
|
|
@ -867,7 +867,7 @@ reopen_tables:
|
|||
tl->lock_type != TL_READ_NO_INSERT)
|
||||
{
|
||||
TABLE_LIST *duplicate;
|
||||
if ((duplicate= unique_table(thd, tl, table_list)))
|
||||
if ((duplicate= unique_table(thd, tl, table_list, 0)))
|
||||
{
|
||||
update_non_unique_table_error(table_list, "UPDATE", duplicate);
|
||||
DBUG_RETURN(TRUE);
|
||||
|
|
@ -1086,7 +1086,7 @@ static bool safe_update_on_fly(THD *thd, JOIN_TAB *join_tab,
|
|||
List<Item> *fields)
|
||||
{
|
||||
TABLE *table= join_tab->table;
|
||||
if (unique_table(thd, table_ref, all_tables))
|
||||
if (unique_table(thd, table_ref, all_tables, 0))
|
||||
return 0;
|
||||
switch (join_tab->type) {
|
||||
case JT_SYSTEM:
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue