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

Merge branch '10.11' into 11.1

This commit is contained in:
Oleksandr Byelkin
2024-08-03 09:32:42 +02:00
461 changed files with 12085 additions and 5128 deletions

View File

@ -4356,7 +4356,16 @@ bool select_insert::prepare_eof()
if (info.ignore || info.handle_duplicates != DUP_ERROR)
if (table->file->ha_table_flags() & HA_DUPLICATE_POS)
table->file->ha_rnd_end();
table->file->extra(HA_EXTRA_END_ALTER_COPY);
if (error <= 0)
{
error= table->file->extra(HA_EXTRA_END_ALTER_COPY);
if (error == HA_ERR_FOUND_DUPP_KEY)
{
uint key_nr= table->file->get_dup_key(error);
if ((int)key_nr >= 0 && key_nr < table->s->keys)
print_keydup_error(table, &table->key_info[key_nr], MYF(0));
}
}
table->file->extra(HA_EXTRA_NO_IGNORE_DUP_KEY);
table->file->extra(HA_EXTRA_WRITE_CANNOT_REPLACE);