Fix of LP BUG#777809
There are 2 volatile condition constructions AND/OR constructions and fields(references) when first good supported to be top elements of conditions because it is normal practice (see copy_andor_structure for example) fields without any expression in the condition is really rare and mostly useless case however it could lead to problems when optimiser changes/moves them unaware of other variables referring to them. An easy solution of this problem is just to replace single field in a condition with equivalent expression well supported by the server (<field> -> <field> != 0). mysql-test/r/view.result: New test added. mysql-test/t/view.test: New test added. sql/sql_parse.cc: <field> -> <field> != 0 sql/sql_yacc.yy: <field> -> <field> != 0
Showing
Please register or sign in to comment