mirror of
https://github.com/MariaDB/server.git
synced 2025-08-08 11:22:35 +03:00
MDEV-35307 Unexpected error WARN_SORTING_ON_TRUNCATED_LENGTH or assertion failure in diagnostics area #2
When strict mode is enabled, all warnings during `INSERT` are converted to errors regardless of their actual severity. `WARN_SORTING_ON_TRUNCATED_LENGTH` is not considered severe enough to be elevated to the ERROR level, and this commit fixes that
This commit is contained in:
@@ -6067,23 +6067,7 @@ public:
|
||||
bool need_report_unit_results();
|
||||
bool report_collected_unit_results();
|
||||
bool init_collecting_unit_results();
|
||||
|
||||
/*
|
||||
Push post-execution warnings, which may be some kinds of aggregate messages
|
||||
like number of times max_sort_length was reached during sorting/grouping
|
||||
*/
|
||||
void push_final_warnings()
|
||||
{
|
||||
if (num_of_strings_sorted_on_truncated_length)
|
||||
{
|
||||
push_warning_printf(this, Sql_condition::WARN_LEVEL_WARN,
|
||||
WARN_SORTING_ON_TRUNCATED_LENGTH,
|
||||
ER_THD(this, WARN_SORTING_ON_TRUNCATED_LENGTH),
|
||||
num_of_strings_sorted_on_truncated_length,
|
||||
variables.max_sort_length);
|
||||
num_of_strings_sorted_on_truncated_length= 0;
|
||||
}
|
||||
}
|
||||
void push_final_warnings();
|
||||
};
|
||||
|
||||
|
||||
|
Reference in New Issue
Block a user