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

MDEV-22420 DDL on temporary object is prohibited when XA is in prepare state

The parser must reject DDL operations on temporary objects when
they may modify or alter such object, including temporary tables and sequences.
The rejection is regardless (has been already in place for bin-loggable DML:s)
of the binlogging capability of the server or connection.

The patch implements the requirement. A binlog test is added.
This commit is contained in:
Andrei Elkin
2020-06-05 16:41:25 +03:00
parent 545a6194e8
commit 127ed74fd2
3 changed files with 68 additions and 0 deletions

View File

@ -4890,6 +4890,8 @@ mysql_execute_command(THD *thd)
}
else
{
if (thd->transaction->xid_state.check_has_uncommitted_xa())
goto error;
status_var_decrement(thd->status_var.com_stat[lex->sql_command]);
status_var_increment(thd->status_var.com_drop_tmp_table);