1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-08 11:22:35 +03:00

Merge branch '10.6' into 10.11

This commit is contained in:
Oleksandr Byelkin
2024-08-20 10:00:39 +02:00
17 changed files with 594 additions and 20 deletions

View File

@@ -830,13 +830,17 @@ bool mysql_delete(THD *thd, TABLE_LIST *table_list, COND *conds,
delete_history);
if (delete_record)
{
void *save_bulk_param= thd->bulk_param;
thd->bulk_param= nullptr;
if (!delete_history && table->triggers &&
table->triggers->process_triggers(thd, TRG_EVENT_DELETE,
TRG_ACTION_BEFORE, FALSE))
{
error= 1;
thd->bulk_param= save_bulk_param;
break;
}
thd->bulk_param= save_bulk_param;
// no LIMIT / OFFSET
if (returning && result->send_data(returning->item_list) < 0)
@@ -867,13 +871,16 @@ bool mysql_delete(THD *thd, TABLE_LIST *table_list, COND *conds,
if (likely(!error))
{
deleted++;
thd->bulk_param= nullptr;
if (!delete_history && table->triggers &&
table->triggers->process_triggers(thd, TRG_EVENT_DELETE,
TRG_ACTION_AFTER, FALSE))
{
error= 1;
thd->bulk_param= save_bulk_param;
break;
}
thd->bulk_param= save_bulk_param;
if (!--limit && using_limit)
{
error= -1;