MDEV-34785: Assertion failure in Item_func_or_sum::do_build_clone (Item_func_not_all)

Missed method added.
This commit is contained in:
Oleksandr Byelkin 2024-08-20 16:12:02 +02:00
parent b68c100076
commit 0b7d19d500
3 changed files with 20 additions and 0 deletions

View File

@ -42,5 +42,14 @@ SELECT * FROM v WHERE f = '10.5.20';
f
drop view v;
#
# MDEV-34785: Assertion failure in Item_func_or_sum::do_build_clone
# (Item_func_not_all)
#
CREATE VIEW t AS SELECT 0 AS a;
SELECT * FROM t WHERE a=ALL (SELECT 0);
a
0
DROP VIEW t;
#
# End of 10.5 tests
#

View File

@ -46,6 +46,15 @@ CREATE VIEW v AS SELECT version() AS f;
SELECT * FROM v WHERE f = '10.5.20';
drop view v;
--echo #
--echo # MDEV-34785: Assertion failure in Item_func_or_sum::do_build_clone
--echo # (Item_func_not_all)
--echo #
CREATE VIEW t AS SELECT 0 AS a;
SELECT * FROM t WHERE a=ALL (SELECT 0);
DROP VIEW t;
--echo #
--echo # End of 10.5 tests
--echo #

View File

@ -711,6 +711,8 @@ public:
void set_sub_test(Item_maxmin_subselect *item) { test_sub_item= item; test_sum_item= 0;};
bool empty_underlying_subquery();
Item *neg_transformer(THD *thd) override;
Item *do_get_copy(THD *thd) const override
{ return get_item_copy<Item_func_not_all>(thd, this); }
};