Fixed bug #28000.
Bug occurs in INSERT IGNORE ... SELECT ... ON DUPLICATE KEY UPDATE statements, when SELECT returns duplicated values and UPDATE clause tries to assign NULL values to NOT NULL fields. NOTE: By current design MySQL server treats INSERT IGNORE ... ON DUPLICATE statements as INSERT ... ON DUPLICATE with update of duplicated records, but MySQL manual lacks this information. After this fix such behaviour becomes legalized. The write_record() function was returning error values even within INSERT IGNORE, because ignore_errors parameter of the fill_record_n_invoke_before_triggers() function call was always set to FALSE. FALSE is replaced by info->ignore.
Showing
Please register or sign in to comment