Bug#13832772 ASSERTION `THD->IS_ERROR() || KILL_ERRNO'
We are trying to sort a lot of text/blob fields, so the buffer is indeed too small. Memory available = thd->variables.sortbuff_size = 262144 min_sort_memory = param.sort_length*MERGEBUFF2 = 292245 So the decision to abort the query is correct. filesort() calls my_error(), the error is reported. But, since we have DELETE IGNORE ... the error is converted to a warning by THD::raise_condition filesort currently expects an error to be recorded in the THD diagnostics area. If we lift this restriction (remove the assert) we end up in the familiar void Protocol::end_statement() default: DBUG_ASSERT(0); The solution seems to be to call my_error(ME_FATALERROR) in filesort, so that the error is propagated as an error rather than a warning. mysql-test/r/filesort_debug.result: New test case. mysql-test/t/filesort_debug.test: New test case.
Showing
Please register or sign in to comment