mirror of
https://github.com/MariaDB/server.git
synced 2026-10-23 18:49:29 +03:00
MDEV-38815 Server crashes in Item_func_nextval::val_int upon update on a view
MDEV-28650 (7a88776dc1) fixed the case when the DEFAULT flag is
inside the table definition but it can be also in DML command. When we
assign it from the table definition in mysql_make_view() we lose it in
the current command.
The fix does disjunction assignment to keep both values. It is
signalling DML_prelocking_strategy::handle_table() to call
add_internal_tables(), so it will correctly open associated sequence
table.
This commit is contained in:
@@ -1720,7 +1720,7 @@ bool mysql_make_view(THD *thd, TABLE_SHARE *share, TABLE_LIST *table,
|
||||
if (lex->first_select_lex()->options & OPTION_TO_QUERY_CACHE)
|
||||
old_lex->first_select_lex()->options|= OPTION_TO_QUERY_CACHE;
|
||||
|
||||
old_lex->default_used= lex->default_used;
|
||||
old_lex->default_used|= lex->default_used;
|
||||
|
||||
#ifndef NO_EMBEDDED_ACCESS_CHECKS
|
||||
if (table->view_suid)
|
||||
|
||||
Reference in New Issue
Block a user