1
0
mirror of https://github.com/MariaDB/server.git synced 2025-07-29 05:21:33 +03:00

Using more of Sql_mode_save. Adding a similar class for THD::abort_on_warnings.

This commit is contained in:
Alexander Barkov
2019-05-28 10:26:08 +04:00
parent c0cd662b98
commit d1d6fe9abf
17 changed files with 65 additions and 71 deletions

View File

@ -3655,10 +3655,8 @@ select_insert::prepare(List<Item> &values, SELECT_LEX_UNIT *u)
if (!res && fields->elements)
{
bool saved_abort_on_warning= thd->abort_on_warning;
thd->abort_on_warning= !info.ignore && thd->is_strict_mode();
Abort_on_warning_instant_set aws(thd, !info.ignore && thd->is_strict_mode());
res= check_that_all_fields_are_given_values(thd, table_list->table, table_list);
thd->abort_on_warning= saved_abort_on_warning;
}
if (info.handle_duplicates == DUP_UPDATE && !res)