1
0
mirror of https://github.com/MariaDB/server.git synced 2026-10-23 18:49:29 +03:00

MDEV-36787 Error 153: No savepoint with that name upon ROLLBACK TO SAVEPOINT, assertion failure

1. InnoDB should return HA_ERR_ROLLBACK if it aborts a transaction internally
2. the server should recognize it and perform an automatic rollback
This commit is contained in:
Sergei Golubchik
2026-01-25 13:20:51 +01:00
parent d08fd6343e
commit 387fe5ecc3
6 changed files with 42 additions and 9 deletions

View File

@@ -4685,7 +4685,8 @@ void select_insert::abort_result_set()
finalize_replace(table, info.handle_duplicates, info.ignore);
table->file->extra(HA_EXTRA_NO_IGNORE_DUP_KEY);
table->file->extra(HA_EXTRA_WRITE_CANNOT_REPLACE);
table->file->extra(HA_EXTRA_ABORT_ALTER_COPY);
if (table->file->extra(HA_EXTRA_ABORT_ALTER_COPY) == HA_ERR_ROLLBACK)
thd->transaction_rollback_request= true;
/*
If at least one row has been inserted/modified and will stay in
the table (the table doesn't have transactions) we must write to