-
unknown authored
Problem: when embedding a character string with introducer with charset X into a SQL query which is generally in character set Y, the string constants were escaped according to their own character set (i.e.X), then after reading such a "mixed" query from binlog, the string constants were unescaped using character set of the query (i.e. Y), instead of X, which gave wrong results or even syntax errors with tricky charsets (e.g. sjis) Fix: when embedding a string constant of charset X into a query of charset Y, the string constant is now escaped according to character Y, instead of its own character set X. mysql-test/r/ctype_cp932_binlog.result: Fixing test results. sql/log_event.cc: Using character set "csinfo" instead of the string character set. sql/sp_head.cc: - adding "thd" argument to sp_get_item_value() to have access to thd->variables.character_set_client - using character_set_client for escaping, instead of the string character set mysql-test/r/rpl_charset_sjis.result: Adding test case mysql-test/t/rpl_charset_sjis.test: Adding test case
29936a68