mirror of
https://github.com/MariaDB/server.git
synced 2025-08-01 03:47:19 +03:00
BUG#35515 Aliases of variables in binary log are ignored with NAME_CONST.
When add an aliase name after NAME_CONST, the aliase name will be overwrite. NAME_CONST will re-set the field's name only if there isn't an aliase in the function fix-fields(). If there is an aliase, NAME_CONST doesn't re-set the field's name and keeps the old name. mysql-test/r/func_misc.result: Test result. mysql-test/r/rpl_name_const.result: Test case. mysql-test/t/func_misc.test: Add NAME_CONST test. mysql-test/t/rpl_name_const.test: Test result. sql/item.cc: Re-set field's name if the name is autogenerated, that mean without aliase.
This commit is contained in:
@ -324,4 +324,7 @@ SELECT * FROM t1 WHERE a = NAME_CONST('reportDate',
|
||||
_binary'2009-01-09' COLLATE 'binary');
|
||||
a
|
||||
DROP TABLE t1;
|
||||
select NAME_CONST('_id',1234) as id;
|
||||
id
|
||||
1234
|
||||
End of 5.0 tests
|
||||
|
Reference in New Issue
Block a user