1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-30 16:24:05 +03:00

check of using same table for changing and select

This commit is contained in:
bell@sanja.is.com.ua
2002-11-30 19:26:18 +02:00
parent fd11c80400
commit 9da705ef2f
8 changed files with 96 additions and 20 deletions

View File

@ -86,6 +86,13 @@ int mysql_update(THD *thd,
setup_conds(thd,update_table_list,&conds)
|| setup_ftfuncs(&thd->lex.select_lex))
DBUG_RETURN(-1); /* purecov: inspected */
if (find_real_table_in_list(table_list->next,
table_list->db, table_list->real_name))
{
my_error(ER_INSERT_TABLE_USED, MYF(0), table_list->real_name);
DBUG_RETURN(-1);
}
old_used_keys=table->used_keys; // Keys used in WHERE
/*