1
0
mirror of https://github.com/MariaDB/server.git synced 2025-08-01 03:47:19 +03:00

MDEV-22058: Assertion `!is_set() || (m_status == DA_OK_BULK && is_bulk_op())' failed in Diagnostics_area::set_ok_status

Error state is not stored in check_and_do_in_subquery_rewrites() when there is
illegal combination of optimizer switches. So all the functions eventually
return false. Thus the assetion failure.
This commit is contained in:
Rucha Deodhar
2020-07-02 19:03:39 +05:30
parent f81ff93287
commit 0994af43e5
10 changed files with 70 additions and 28 deletions

View File

@ -3851,3 +3851,22 @@ SELECT @msg;
DROP FUNCTION f1;
DROP FUNCTION f2;
DROP TABLE t1;
--echo #
--echo # 10.2 Test
--echo #
--echo # MDEV-MDEV-22058: Assertion `!is_set() || (m_status == DA_OK_BULK &&
--echo # is_bulk_op())' failed in Diagnostics_area::set_ok_status
--echo #
SET @old_optimizer_switch = @@SESSION.OPTIMIZER_SWITCH;
SET @cmd:="SET @@SESSION.SQL_MODE=(SELECT 'a')";
--error ER_ILLEGAL_SUBQUERY_OPTIMIZER_SWITCHES
SET @@SESSION.OPTIMIZER_SWITCH="in_to_exists=OFF,materialization=OFF";
PREPARE stmt FROM @cmd;
set @@SESSION.OPTIMIZER_SWITCH=@old_optimizer_switch;
--echo # End of 10.2 Test