mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
Merge 10.5 into 10.6
This commit is contained in:
@@ -8728,7 +8728,6 @@ void switch_to_nullable_trigger_fields(List<Item> &items, TABLE *table)
|
||||
|
||||
while ((item= it++))
|
||||
item->walk(&Item::switch_to_nullable_fields_processor, 1, field);
|
||||
table->triggers->reset_extra_null_bitmap();
|
||||
}
|
||||
}
|
||||
|
||||
@@ -8782,8 +8781,14 @@ static bool not_null_fields_have_null_values(TABLE *table)
|
||||
swap_variables(uint32, of->flags, ff->flags);
|
||||
if (ff->is_real_null())
|
||||
{
|
||||
uint err= ER_BAD_NULL_ERROR;
|
||||
if (ff->flags & NO_DEFAULT_VALUE_FLAG && !ff->has_explicit_value())
|
||||
{
|
||||
err= ER_NO_DEFAULT_FOR_FIELD;
|
||||
table->in_use->count_cuted_fields= CHECK_FIELD_WARN;
|
||||
}
|
||||
ff->set_notnull(); // for next row WHERE condition in UPDATE
|
||||
if (convert_null_to_field_value_or_error(of) || thd->is_error())
|
||||
if (convert_null_to_field_value_or_error(of, err) || thd->is_error())
|
||||
return true;
|
||||
}
|
||||
}
|
||||
@@ -9059,8 +9064,9 @@ my_bool mysql_rm_tmp_tables(void)
|
||||
memcpy(path_copy, path, path_len - ext_len);
|
||||
path_copy[path_len - ext_len]= 0;
|
||||
init_tmp_table_share(thd, &share, "", 0, "", path_copy);
|
||||
handlerton *ht= share.db_type();
|
||||
if (!open_table_def(thd, &share))
|
||||
share.db_type()->drop_table(share.db_type(), path_copy);
|
||||
ht->drop_table(share.db_type(), path_copy);
|
||||
free_table_share(&share);
|
||||
}
|
||||
/*
|
||||
|
Reference in New Issue
Block a user