mirror of
https://github.com/MariaDB/server.git
synced 2026-04-29 11:45:32 +02:00
MDEV-8256 A part of a ROW comparison is erroneously optimized away
Item_func_eq's created during conversion of a ROW equality to a conjunction of scalar equalities did not set cmp_context for its arguments properly, so some of these created Item_func_eq could be later erroneously eliminated.
This commit is contained in:
parent
4a7afdde86
commit
a4b0063d7b
4 changed files with 55 additions and 2 deletions
|
|
@ -325,6 +325,14 @@ public:
|
|||
{
|
||||
return cmp.set_cmp_func(this, tmp_arg, tmp_arg + 1, true);
|
||||
}
|
||||
bool set_cmp_func_and_arg_cmp_context()
|
||||
{
|
||||
if (set_cmp_func())
|
||||
return true;
|
||||
tmp_arg[0]->cmp_context= tmp_arg[1]->cmp_context=
|
||||
item_cmp_type(tmp_arg[0]->result_type(), tmp_arg[1]->result_type());
|
||||
return false;
|
||||
}
|
||||
CHARSET_INFO *compare_collation() const
|
||||
{ return cmp.cmp_collation.collation; }
|
||||
Arg_comparator *get_comparator() { return &cmp; }
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue