returns one row:
Now if I make the condition even stroger:
It erroneously returns two rows:
It should return one row.
The problem happens in equal fields propagation in this code:
Item_func_in does not set cmp_type of args, so has_compatible_context() passes and the field gets erroneously replaced to the string constant which makes Item_func_in::val_int() always evaluate to TRUE.