summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--mysql-test/r/mysqlbinlog.result32
-rw-r--r--mysql-test/r/mysqlbinlog2.result70
-rw-r--r--mysql-test/r/mysqlbinlog_row.result384
-rw-r--r--mysql-test/r/mysqlbinlog_row_innodb.result210
-rw-r--r--mysql-test/r/mysqlbinlog_row_myisam.result210
-rw-r--r--mysql-test/r/mysqlbinlog_row_trans.result58
-rw-r--r--mysql-test/r/user_var-binlog.result2
-rw-r--r--mysql-test/suite/binlog/r/binlog_base64_flag.result2
-rw-r--r--mysql-test/suite/binlog/r/binlog_database.result6
-rw-r--r--mysql-test/suite/binlog/r/binlog_row_mysqlbinlog_verbose.result56
-rw-r--r--mysql-test/suite/binlog/r/binlog_stm_ctype_ucs.result2
-rw-r--r--mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result8
-rw-r--r--mysql-test/suite/rpl/r/rpl_sp.result12
-rw-r--r--sql/ha_ndbcluster_binlog.cc31
-rw-r--r--sql/log.cc33
-rw-r--r--sql/log_event.cc209
-rw-r--r--sql/log_event.h17
-rw-r--r--sql/sql_base.cc31
-rw-r--r--sql/sql_db.cc34
-rw-r--r--sql/sql_load.cc29
-rw-r--r--sql/sql_show.cc3
-rw-r--r--sql/sql_show.h1
-rw-r--r--sql/sql_table.cc21
-rw-r--r--sql/sql_truncate.cc34
24 files changed, 835 insertions, 660 deletions
diff --git a/mysql-test/r/mysqlbinlog.result b/mysql-test/r/mysqlbinlog.result
index 5a47b6700c0..587a4de8a64 100644
--- a/mysql-test/r/mysqlbinlog.result
+++ b/mysql-test/r/mysqlbinlog.result
@@ -18,7 +18,7 @@ flush logs;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -111,7 +111,7 @@ SET @@session.lc_time_names=0/*!*/;
SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (`word`)
/*!*/;
@@ -202,7 +202,7 @@ SET @@session.lc_time_names=0/*!*/;
SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
insert into t1 values ("Alas")
/*!*/;
@@ -219,7 +219,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -312,7 +312,7 @@ SET @@session.lc_time_names=0/*!*/;
SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
LOAD DATA LOCAL INFILE 'MYSQLTEST_VARDIR/tmp/SQL_LOAD_MB-#-#' INTO TABLE `t1` FIELDS TERMINATED BY '\t' ENCLOSED BY '' ESCAPED BY '\\' LINES TERMINATED BY '\n' (`word`)
/*!*/;
@@ -403,7 +403,7 @@ SET @@session.lc_time_names=0/*!*/;
SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
insert into t1 values ("Alas")
/*!*/;
@@ -420,7 +420,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1108844556/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
@@ -438,7 +438,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1108844556/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.auto_increment_increment=1, @@session.auto_increment_offset=1/*!*/;
@@ -498,7 +498,7 @@ ERROR 42000: PROCEDURE test.p1 does not exist
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -548,7 +548,7 @@ flush logs;
/*!40019 SET @@session.max_insert_delayed_threads=0*/;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -725,7 +725,7 @@ FLUSH LOGS;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1253783037/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=1, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -822,22 +822,22 @@ SET @@session.lc_time_names=0/*!*/;
SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1266652094/*!*/;
SavePoint mixed_cases
/*!*/;
-use db1/*!*/;
+use `db1`/*!*/;
SET TIMESTAMP=1266652094/*!*/;
INSERT INTO db1.t2 VALUES("in savepoint mixed_cases")
/*!*/;
SET TIMESTAMP=1266652094/*!*/;
INSERT INTO db1.t1 VALUES(40)
/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1266652094/*!*/;
ROLLBACK TO mixed_cases
/*!*/;
-use db1/*!*/;
+use `db1`/*!*/;
SET TIMESTAMP=1266652094/*!*/;
INSERT INTO db1.t2 VALUES("after rollback to")
/*!*/;
@@ -865,7 +865,7 @@ SET @@session.lc_time_names=0/*!*/;
SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1266652094/*!*/;
SavePoint mixed_cases
/*!*/;
diff --git a/mysql-test/r/mysqlbinlog2.result b/mysql-test/r/mysqlbinlog2.result
index 52a589ca7c1..806cf74479e 100644
--- a/mysql-test/r/mysqlbinlog2.result
+++ b/mysql-test/r/mysqlbinlog2.result
@@ -19,7 +19,7 @@ insert into t1 values(null, "f");
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -103,7 +103,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=1/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
insert into t1 values(null, "a")
/*!*/;
@@ -172,7 +172,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -209,7 +209,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -263,7 +263,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -289,7 +289,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -326,7 +326,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -369,7 +369,7 @@ flush logs;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -445,7 +445,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=6/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609943/*!*/;
insert into t1 values(null, "f")
/*!*/;
@@ -474,7 +474,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=1/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
insert into t1 values(null, "a")
/*!*/;
@@ -535,7 +535,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=6/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609943/*!*/;
insert into t1 values(null, "f")
/*!*/;
@@ -564,7 +564,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -605,7 +605,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=6/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609943/*!*/;
insert into t1 values(null, "f")
/*!*/;
@@ -622,7 +622,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -720,7 +720,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -761,7 +761,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=6/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609943/*!*/;
insert into t1 values(null, "f")
/*!*/;
@@ -778,7 +778,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -820,7 +820,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -904,7 +904,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=1/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
insert into t1 values(null, "a")
/*!*/;
@@ -972,7 +972,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -1009,7 +1009,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -1062,7 +1062,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -1088,7 +1088,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -1125,7 +1125,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -1167,7 +1167,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -1243,7 +1243,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=6/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609943/*!*/;
insert into t1 values(null, "f")
/*!*/;
@@ -1272,7 +1272,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=1/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
insert into t1 values(null, "a")
/*!*/;
@@ -1333,7 +1333,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=6/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609943/*!*/;
insert into t1 values(null, "f")
/*!*/;
@@ -1361,7 +1361,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -1402,7 +1402,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=6/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609943/*!*/;
insert into t1 values(null, "f")
/*!*/;
@@ -1419,7 +1419,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -1516,7 +1516,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=3/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609944/*!*/;
insert into t1 values(null, "c")
/*!*/;
@@ -1557,7 +1557,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET INSERT_ID=6/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609943/*!*/;
insert into t1 values(null, "f")
/*!*/;
@@ -1574,7 +1574,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -1616,7 +1616,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1579609942/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
diff --git a/mysql-test/r/mysqlbinlog_row.result b/mysql-test/r/mysqlbinlog_row.result
index 7ae1ea36899..84a6d6c3baf 100644
--- a/mysql-test/r/mysqlbinlog_row.result
+++ b/mysql-test/r/mysqlbinlog_row.result
@@ -336,7 +336,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -357,7 +357,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
# at #
@@ -374,7 +374,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
# at #
@@ -401,7 +401,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0000001' /* BIT(7) meta=7 nullable=1 is_null=0 */
# at #
@@ -418,7 +418,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0000010' /* BIT(7) meta=7 nullable=1 is_null=0 */
# at #
@@ -435,7 +435,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0000100' /* BIT(7) meta=7 nullable=1 is_null=0 */
# at #
@@ -452,7 +452,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0001000' /* BIT(7) meta=7 nullable=1 is_null=0 */
# at #
@@ -469,7 +469,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0010000' /* BIT(7) meta=7 nullable=1 is_null=0 */
# at #
@@ -486,7 +486,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0100000' /* BIT(7) meta=7 nullable=1 is_null=0 */
# at #
@@ -503,7 +503,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'1000000' /* BIT(7) meta=7 nullable=1 is_null=0 */
# at #
@@ -520,7 +520,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'1111111' /* BIT(7) meta=7 nullable=1 is_null=0 */
# at #
@@ -537,7 +537,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=b'1111111' /* BIT(7) meta=7 nullable=1 is_null=0 */
# at #
@@ -554,7 +554,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=b'0010000' /* BIT(7) meta=7 nullable=1 is_null=0 */
### SET
@@ -583,7 +583,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'00010010010010001001' /* BIT(20) meta=516 nullable=1 is_null=0 */
### @2='ab' /* STRING(2) meta=65026 nullable=1 is_null=0 */
@@ -611,7 +611,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0000000000000000000000000000000000000000000000000000000000000001' /* BIT(64) meta=2048 nullable=1 is_null=0 */
# at #
@@ -628,7 +628,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0000000000000000000000000000000000000000000000000000000000000010' /* BIT(64) meta=2048 nullable=1 is_null=0 */
# at #
@@ -645,7 +645,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0000000000000000000000000000000000000000000000000000000010000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
# at #
@@ -662,7 +662,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
# at #
@@ -689,13 +689,13 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=1 /* TINYINT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=2 /* TINYINT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=3 /* TINYINT meta=0 nullable=1 is_null=0 */
# at #
@@ -712,7 +712,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-128 (128) /* TINYINT meta=0 nullable=1 is_null=0 */
# at #
@@ -729,7 +729,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=1 /* TINYINT meta=0 nullable=1 is_null=0 */
### SET
@@ -748,7 +748,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=-128 (128) /* TINYINT meta=0 nullable=1 is_null=0 */
# at #
@@ -775,10 +775,10 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-128 (128) /* TINYINT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-1 (255) /* TINYINT meta=0 nullable=1 is_null=0 */
# at #
@@ -795,7 +795,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=-1 (255) /* TINYINT meta=0 nullable=1 is_null=0 */
# at #
@@ -822,7 +822,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=1 /* TINYINT meta=0 nullable=1 is_null=0 */
# at #
@@ -839,7 +839,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=1 /* TINYINT meta=0 nullable=1 is_null=0 */
# at #
@@ -866,7 +866,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=1234 /* SHORTINT meta=0 nullable=1 is_null=0 */
# at #
@@ -883,7 +883,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=1234 /* SHORTINT meta=0 nullable=1 is_null=0 */
# at #
@@ -910,10 +910,10 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-32768 (32768) /* SHORTINT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-1 (65535) /* SHORTINT meta=0 nullable=1 is_null=0 */
# at #
@@ -930,7 +930,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=-32768 (32768) /* SHORTINT meta=0 nullable=1 is_null=0 */
### SET
@@ -949,7 +949,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=-1 (65535) /* SHORTINT meta=0 nullable=1 is_null=0 */
# at #
@@ -976,7 +976,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=12345 /* MEDIUMINT meta=0 nullable=1 is_null=0 */
# at #
@@ -993,7 +993,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=12345 /* MEDIUMINT meta=0 nullable=1 is_null=0 */
# at #
@@ -1020,10 +1020,10 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-8388608 (8388608) /* MEDIUMINT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-1 (16777215) /* MEDIUMINT meta=0 nullable=1 is_null=0 */
# at #
@@ -1040,7 +1040,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=-8388608 (8388608) /* MEDIUMINT meta=0 nullable=1 is_null=0 */
### SET
@@ -1059,7 +1059,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=-1 (16777215) /* MEDIUMINT meta=0 nullable=1 is_null=0 */
# at #
@@ -1086,7 +1086,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=123456 /* INT meta=0 nullable=1 is_null=0 */
# at #
@@ -1103,7 +1103,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=123456 /* INT meta=0 nullable=1 is_null=0 */
# at #
@@ -1130,10 +1130,10 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-2147483648 (2147483648) /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-1 (4294967295) /* INT meta=0 nullable=1 is_null=0 */
# at #
@@ -1150,7 +1150,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=-2147483648 (2147483648) /* INT meta=0 nullable=1 is_null=0 */
### SET
@@ -1169,7 +1169,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=-1 (4294967295) /* INT meta=0 nullable=1 is_null=0 */
# at #
@@ -1196,7 +1196,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=1234567890 /* LONGINT meta=0 nullable=1 is_null=0 */
# at #
@@ -1213,7 +1213,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=1234567890 /* LONGINT meta=0 nullable=1 is_null=0 */
# at #
@@ -1240,10 +1240,10 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-9223372036854775808 (9223372036854775808) /* LONGINT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-1 (18446744073709551615) /* LONGINT meta=0 nullable=1 is_null=0 */
# at #
@@ -1260,7 +1260,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=-9223372036854775808 (9223372036854775808) /* LONGINT meta=0 nullable=1 is_null=0 */
### SET
@@ -1279,7 +1279,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=-1 (18446744073709551615) /* LONGINT meta=0 nullable=1 is_null=0 */
# at #
@@ -1306,7 +1306,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=123.223... /* FLOAT meta=4 nullable=1 is_null=0 */
# at #
@@ -1323,7 +1323,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=123.223... /* FLOAT meta=4 nullable=1 is_null=0 */
# at #
@@ -1350,7 +1350,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=123434.223... /* DOUBLE meta=8 nullable=1 is_null=0 */
# at #
@@ -1367,7 +1367,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=123434.223... /* DOUBLE meta=8 nullable=1 is_null=0 */
# at #
@@ -1394,7 +1394,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=000000124.450000000 /* DECIMAL(10,5) meta=2565 nullable=1 is_null=0 */
# at #
@@ -1411,7 +1411,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=-000000543.210000000 /* DECIMAL(10,5) meta=2565 nullable=1 is_null=0 */
# at #
@@ -1428,7 +1428,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=000000124.450000000 /* DECIMAL(10,5) meta=2565 nullable=1 is_null=0 */
# at #
@@ -1455,7 +1455,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2001:02:03' /* DATE meta=0 nullable=1 is_null=0 */
# at #
@@ -1472,7 +1472,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2001:02:03' /* DATE meta=0 nullable=1 is_null=0 */
# at #
@@ -1499,7 +1499,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=2001-02-03 10:20:30 /* DATETIME meta=0 nullable=1 is_null=0 */
# at #
@@ -1516,7 +1516,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=2001-02-03 10:20:30 /* DATETIME meta=0 nullable=1 is_null=0 */
# at #
@@ -1544,7 +1544,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=981184830 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
# at #
@@ -1561,7 +1561,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=981184830 /* TIMESTAMP meta=0 nullable=0 is_null=0 */
# at #
@@ -1588,7 +1588,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='11:22:33' /* TIME meta=0 nullable=1 is_null=0 */
# at #
@@ -1605,7 +1605,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='11:22:33' /* TIME meta=0 nullable=1 is_null=0 */
# at #
@@ -1632,7 +1632,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=2001 /* YEAR meta=0 nullable=1 is_null=0 */
# at #
@@ -1649,7 +1649,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=2001 /* YEAR meta=0 nullable=1 is_null=0 */
# at #
@@ -1676,7 +1676,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -1693,7 +1693,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='a' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -1720,7 +1720,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* STRING(0) meta=65024 nullable=1 is_null=0 */
# at #
@@ -1737,7 +1737,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='' /* STRING(0) meta=65024 nullable=1 is_null=0 */
# at #
@@ -1764,7 +1764,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='b' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -1781,7 +1781,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='b' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -1808,7 +1808,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='ccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc' /* STRING(255) meta=65279 nullable=1 is_null=0 */
# at #
@@ -1825,7 +1825,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='ccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccccc' /* STRING(255) meta=65279 nullable=1 is_null=0 */
# at #
@@ -1852,7 +1852,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a' /* STRING(3) meta=65027 nullable=1 is_null=0 */
# at #
@@ -1869,7 +1869,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='a' /* STRING(3) meta=65027 nullable=1 is_null=0 */
# at #
@@ -1896,7 +1896,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* STRING(0) meta=65024 nullable=1 is_null=0 */
# at #
@@ -1913,7 +1913,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='' /* STRING(0) meta=65024 nullable=1 is_null=0 */
# at #
@@ -1940,7 +1940,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a' /* STRING(3) meta=65027 nullable=1 is_null=0 */
# at #
@@ -1957,7 +1957,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='a' /* STRING(3) meta=65027 nullable=1 is_null=0 */
# at #
@@ -1984,7 +1984,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* STRING(765) meta=57085 nullable=1 is_null=0 */
# at #
@@ -2001,7 +2001,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß' /* STRING(765) meta=57085 nullable=1 is_null=0 */
# at #
@@ -2018,10 +2018,10 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* STRING(765) meta=57085 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß' /* STRING(765) meta=57085 nullable=1 is_null=0 */
# at #
@@ -2048,7 +2048,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00a' /* STRING(2) meta=65026 nullable=1 is_null=0 */
# at #
@@ -2065,7 +2065,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00a' /* STRING(2) meta=65026 nullable=1 is_null=0 */
# at #
@@ -2092,7 +2092,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* STRING(0) meta=65024 nullable=1 is_null=0 */
# at #
@@ -2109,7 +2109,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='' /* STRING(0) meta=65024 nullable=1 is_null=0 */
# at #
@@ -2136,7 +2136,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00a' /* STRING(2) meta=65026 nullable=1 is_null=0 */
# at #
@@ -2153,7 +2153,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00a' /* STRING(2) meta=65026 nullable=1 is_null=0 */
# at #
@@ -2180,7 +2180,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a' /* STRING(510) meta=61182 nullable=1 is_null=0 */
# at #
@@ -2197,7 +2197,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß' /* STRING(510) meta=61182 nullable=1 is_null=0 */
# at #
@@ -2216,10 +2216,10 @@ BEGIN
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a' /* STRING(510) meta=61182 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß\x00ß' /* STRING(510) meta=61182 nullable=1 is_null=0 */
# at #
@@ -2246,7 +2246,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* VARSTRING(0) meta=0 nullable=1 is_null=0 */
# at #
@@ -2263,7 +2263,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='' /* VARSTRING(0) meta=0 nullable=1 is_null=0 */
# at #
@@ -2290,7 +2290,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a' /* VARSTRING(1) meta=1 nullable=1 is_null=0 */
# at #
@@ -2307,7 +2307,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='a' /* VARSTRING(1) meta=1 nullable=1 is_null=0 */
# at #
@@ -2334,7 +2334,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
# at #
@@ -2351,7 +2351,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
# at #
@@ -2378,7 +2378,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* VARSTRING(261) meta=261 nullable=1 is_null=0 */
# at #
@@ -2395,7 +2395,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* VARSTRING(261) meta=261 nullable=1 is_null=0 */
# at #
@@ -2422,7 +2422,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* VARSTRING(0) meta=0 nullable=1 is_null=0 */
# at #
@@ -2439,7 +2439,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='' /* VARSTRING(0) meta=0 nullable=1 is_null=0 */
# at #
@@ -2466,7 +2466,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a' /* VARSTRING(3) meta=3 nullable=1 is_null=0 */
# at #
@@ -2483,7 +2483,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='a' /* VARSTRING(3) meta=3 nullable=1 is_null=0 */
# at #
@@ -2510,7 +2510,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* VARSTRING(765) meta=765 nullable=1 is_null=0 */
# at #
@@ -2527,7 +2527,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß' /* VARSTRING(765) meta=765 nullable=1 is_null=0 */
# at #
@@ -2544,10 +2544,10 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* VARSTRING(765) meta=765 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß' /* VARSTRING(765) meta=765 nullable=1 is_null=0 */
# at #
@@ -2574,7 +2574,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* VARSTRING(783) meta=783 nullable=1 is_null=0 */
# at #
@@ -2591,7 +2591,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß' /* VARSTRING(783) meta=783 nullable=1 is_null=0 */
# at #
@@ -2608,10 +2608,10 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='aaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaaa' /* VARSTRING(783) meta=783 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='ßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßßß' /* VARSTRING(783) meta=783 nullable=1 is_null=0 */
# at #
@@ -2638,7 +2638,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* VARSTRING(0) meta=0 nullable=1 is_null=0 */
# at #
@@ -2655,7 +2655,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='' /* VARSTRING(0) meta=0 nullable=1 is_null=0 */
# at #
@@ -2682,7 +2682,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00a' /* VARSTRING(2) meta=2 nullable=1 is_null=0 */
# at #
@@ -2699,7 +2699,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00a' /* VARSTRING(2) meta=2 nullable=1 is_null=0 */
# at #
@@ -2726,7 +2726,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b' /* VARSTRING(510) meta=510 nullable=1 is_null=0 */
# at #
@@ -2743,7 +2743,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b' /* VARSTRING(510) meta=510 nullable=1 is_null=0 */
# at #
@@ -2770,7 +2770,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b' /* VARSTRING(522) meta=522 nullable=1 is_null=0 */
# at #
@@ -2787,7 +2787,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b\x00a\x00b' /* VARSTRING(522) meta=522 nullable=1 is_null=0 */
# at #
@@ -2814,7 +2814,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -2831,7 +2831,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x02' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -2848,7 +2848,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -2865,7 +2865,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='a' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -2892,7 +2892,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* STRING(0) meta=65024 nullable=1 is_null=0 */
# at #
@@ -2909,7 +2909,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='' /* STRING(0) meta=65024 nullable=1 is_null=0 */
# at #
@@ -2936,7 +2936,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -2953,7 +2953,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x02' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -2970,7 +2970,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -2987,7 +2987,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='a' /* STRING(1) meta=65025 nullable=1 is_null=0 */
# at #
@@ -3014,7 +3014,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* STRING(255) meta=65279 nullable=1 is_null=0 */
# at #
@@ -3031,7 +3031,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x02' /* STRING(255) meta=65279 nullable=1 is_null=0 */
# at #
@@ -3048,7 +3048,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a' /* STRING(255) meta=65279 nullable=1 is_null=0 */
# at #
@@ -3065,7 +3065,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='' /* STRING(255) meta=65279 nullable=1 is_null=0 */
# at #
@@ -3092,7 +3092,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='' /* VARSTRING(0) meta=0 nullable=1 is_null=0 */
# at #
@@ -3109,7 +3109,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='' /* VARSTRING(0) meta=0 nullable=1 is_null=0 */
# at #
@@ -3136,7 +3136,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00' /* VARSTRING(1) meta=1 nullable=1 is_null=0 */
# at #
@@ -3153,7 +3153,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x02' /* VARSTRING(1) meta=1 nullable=1 is_null=0 */
# at #
@@ -3170,7 +3170,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a' /* VARSTRING(1) meta=1 nullable=1 is_null=0 */
# at #
@@ -3187,7 +3187,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x02' /* VARSTRING(1) meta=1 nullable=1 is_null=0 */
# at #
@@ -3214,7 +3214,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
# at #
@@ -3231,7 +3231,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
# at #
@@ -3248,7 +3248,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00a\x00' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
# at #
@@ -3265,7 +3265,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
# at #
@@ -3292,7 +3292,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='tinyblob1' /* TINYBLOB/TINYTEXT meta=1 nullable=1 is_null=0 */
# at #
@@ -3309,7 +3309,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='tinyblob1' /* TINYBLOB/TINYTEXT meta=1 nullable=1 is_null=0 */
# at #
@@ -3336,7 +3336,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='blob1' /* BLOB/TEXT meta=2 nullable=1 is_null=0 */
# at #
@@ -3353,7 +3353,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='blob1' /* BLOB/TEXT meta=2 nullable=1 is_null=0 */
# at #
@@ -3380,7 +3380,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='mediumblob1' /* MEDIUMBLOB/MEDIUMTEXT meta=3 nullable=1 is_null=0 */
# at #
@@ -3397,7 +3397,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='mediumblob1' /* MEDIUMBLOB/MEDIUMTEXT meta=3 nullable=1 is_null=0 */
# at #
@@ -3424,7 +3424,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='longblob1' /* LONGBLOB/LONGTEXT meta=4 nullable=1 is_null=0 */
# at #
@@ -3441,7 +3441,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='longblob1' /* LONGBLOB/LONGTEXT meta=4 nullable=1 is_null=0 */
# at #
@@ -3468,7 +3468,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='tinytext1' /* TINYBLOB/TINYTEXT meta=1 nullable=1 is_null=0 */
# at #
@@ -3485,7 +3485,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='tinytext1' /* TINYBLOB/TINYTEXT meta=1 nullable=1 is_null=0 */
# at #
@@ -3512,7 +3512,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='text1' /* BLOB/TEXT meta=2 nullable=1 is_null=0 */
# at #
@@ -3529,7 +3529,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='text1' /* BLOB/TEXT meta=2 nullable=1 is_null=0 */
# at #
@@ -3556,7 +3556,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='mediumtext1' /* MEDIUMBLOB/MEDIUMTEXT meta=3 nullable=1 is_null=0 */
# at #
@@ -3573,7 +3573,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='mediumtext1' /* MEDIUMBLOB/MEDIUMTEXT meta=3 nullable=1 is_null=0 */
# at #
@@ -3600,7 +3600,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='longtext1' /* LONGBLOB/LONGTEXT meta=4 nullable=1 is_null=0 */
# at #
@@ -3617,7 +3617,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='longtext1' /* LONGBLOB/LONGTEXT meta=4 nullable=1 is_null=0 */
# at #
@@ -3644,7 +3644,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00t\x00i\x00n\x00y\x00t\x00e\x00x\x00t\x001' /* TINYBLOB/TINYTEXT meta=1 nullable=1 is_null=0 */
# at #
@@ -3661,7 +3661,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00t\x00i\x00n\x00y\x00t\x00e\x00x\x00t\x001' /* TINYBLOB/TINYTEXT meta=1 nullable=1 is_null=0 */
# at #
@@ -3688,7 +3688,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00t\x00e\x00x\x00t\x001' /* BLOB/TEXT meta=2 nullable=1 is_null=0 */
# at #
@@ -3705,7 +3705,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00t\x00e\x00x\x00t\x001' /* BLOB/TEXT meta=2 nullable=1 is_null=0 */
# at #
@@ -3732,7 +3732,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00m\x00e\x00d\x00i\x00u\x00m\x00t\x00e\x00x\x00t\x001' /* MEDIUMBLOB/MEDIUMTEXT meta=3 nullable=1 is_null=0 */
# at #
@@ -3749,7 +3749,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00m\x00e\x00d\x00i\x00u\x00m\x00t\x00e\x00x\x00t\x001' /* MEDIUMBLOB/MEDIUMTEXT meta=3 nullable=1 is_null=0 */
# at #
@@ -3776,7 +3776,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='\x00l\x00o\x00n\x00g\x00t\x00e\x00x\x00t\x001' /* LONGBLOB/LONGTEXT meta=4 nullable=1 is_null=0 */
# at #
@@ -3793,7 +3793,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='\x00l\x00o\x00n\x00g\x00t\x00e\x00x\x00t\x001' /* LONGBLOB/LONGTEXT meta=4 nullable=1 is_null=0 */
# at #
@@ -3820,7 +3820,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=2 /* ENUM(1 byte) meta=63233 nullable=1 is_null=0 */
# at #
@@ -3837,7 +3837,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=2 /* ENUM(1 byte) meta=63233 nullable=1 is_null=0 */
# at #
@@ -3864,7 +3864,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'00000011' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
# at #
@@ -3881,7 +3881,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'00000101' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
# at #
@@ -3898,7 +3898,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'00000110' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
# at #
@@ -3915,7 +3915,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'00000111' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
# at #
@@ -3932,7 +3932,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'00001111' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
# at #
@@ -3949,7 +3949,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'00011111' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
# at #
@@ -3966,7 +3966,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'00111111' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
# at #
@@ -3983,7 +3983,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=b'00000011' /* SET(1 bytes) meta=63489 nullable=1 is_null=0 */
# at #
@@ -4015,7 +4015,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=1 /* INT meta=0 nullable=0 is_null=0 */
### @2=0 /* INT meta=0 nullable=0 is_null=0 */
@@ -4033,7 +4033,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=0 /* INT meta=0 nullable=0 is_null=0 */
### @2=1 /* INT meta=0 nullable=0 is_null=0 */
@@ -4051,7 +4051,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1=1 /* INT meta=0 nullable=0 is_null=0 */
### @2=0 /* INT meta=0 nullable=0 is_null=0 */
@@ -4069,7 +4069,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1=0 /* INT meta=0 nullable=0 is_null=0 */
### @2=1 /* INT meta=0 nullable=0 is_null=0 */
@@ -4091,28 +4091,28 @@ BEGIN
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=1 /* INT meta=0 nullable=0 is_null=0 */
### @2=0 /* INT meta=0 nullable=0 is_null=0 */
### SET
### @1=10 /* INT meta=0 nullable=0 is_null=0 */
### @2=0 /* INT meta=0 nullable=0 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=0 /* INT meta=0 nullable=0 is_null=0 */
### @2=1 /* INT meta=0 nullable=0 is_null=0 */
### SET
### @1=10 /* INT meta=0 nullable=0 is_null=0 */
### @2=1 /* INT meta=0 nullable=0 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1=1 /* INT meta=0 nullable=0 is_null=0 */
### @2=0 /* INT meta=0 nullable=0 is_null=0 */
### SET
### @1=20 /* INT meta=0 nullable=0 is_null=0 */
### @2=0 /* INT meta=0 nullable=0 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1=0 /* INT meta=0 nullable=0 is_null=0 */
### @2=1 /* INT meta=0 nullable=0 is_null=0 */
diff --git a/mysql-test/r/mysqlbinlog_row_innodb.result b/mysql-test/r/mysqlbinlog_row_innodb.result
index 00a3eb79b64..31d7ee0df98 100644
--- a/mysql-test/r/mysqlbinlog_row_innodb.result
+++ b/mysql-test/r/mysqlbinlog_row_innodb.result
@@ -2253,7 +2253,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -2363,7 +2363,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -2456,7 +2456,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -2551,7 +2551,7 @@ BEGIN
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
@@ -2632,7 +2632,7 @@ BEGIN
### @77=NULL /* TIMESTAMP meta=63233 nullable=1 is_null=1 */
### @78=NULL /* TIMESTAMP meta=63489 nullable=1 is_null=1 */
### @79=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -2725,7 +2725,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -2898,7 +2898,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3071,7 +3071,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
@@ -3244,7 +3244,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3417,7 +3417,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3510,7 +3510,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3603,7 +3603,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3696,7 +3696,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
@@ -3876,7 +3876,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -3901,47 +3901,47 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=1 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-04' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-05' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-06' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-07' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:08' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-08' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=8 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:09' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-09' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -3958,7 +3958,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -3967,7 +3967,7 @@ BEGIN
### @1='2008:08:11' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=1 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -3976,7 +3976,7 @@ BEGIN
### @1='2008:08:12' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -3985,7 +3985,7 @@ BEGIN
### @1='2008:08:13' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-04' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -3994,7 +3994,7 @@ BEGIN
### @1='2008:08:14' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-04' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-05' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4003,7 +4003,7 @@ BEGIN
### @1='2008:08:15' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-05' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-06' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4012,7 +4012,7 @@ BEGIN
### @1='2008:08:16' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-06' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-07' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4033,37 +4033,37 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:11' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=1 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:12' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:13' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:14' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-04' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:15' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-05' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:16' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-06' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:17' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-07' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4243,7 +4243,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -4286,47 +4286,47 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-01' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=11 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:08' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-08' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=18 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:09' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-09' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4343,47 +4343,47 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-01' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=21 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:08' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-08' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=28 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:09' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-09' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4400,47 +4400,47 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t3` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-01' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=31 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:08' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-08' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=38 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:09' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-09' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4465,7 +4465,7 @@ BEGIN
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4474,7 +4474,7 @@ BEGIN
### @1='2018:01:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4483,7 +4483,7 @@ BEGIN
### @1='2018:01:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4492,7 +4492,7 @@ BEGIN
### @1='2018:01:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4501,7 +4501,7 @@ BEGIN
### @1='2018:01:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4510,7 +4510,7 @@ BEGIN
### @1='2018:01:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4519,7 +4519,7 @@ BEGIN
### @1='2018:01:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4528,7 +4528,7 @@ BEGIN
### @1='2028:02:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4537,7 +4537,7 @@ BEGIN
### @1='2028:02:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4546,7 +4546,7 @@ BEGIN
### @1='2028:02:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4555,7 +4555,7 @@ BEGIN
### @1='2028:02:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4564,7 +4564,7 @@ BEGIN
### @1='2028:02:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4573,7 +4573,7 @@ BEGIN
### @1='2028:02:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4582,7 +4582,7 @@ BEGIN
### @1='2038:03:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4591,7 +4591,7 @@ BEGIN
### @1='2038:03:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4600,7 +4600,7 @@ BEGIN
### @1='2038:03:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4609,7 +4609,7 @@ BEGIN
### @1='2038:03:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4618,7 +4618,7 @@ BEGIN
### @1='2038:03:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4647,92 +4647,92 @@ BEGIN
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4804,7 +4804,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -4829,17 +4829,17 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2=2 /* INT meta=0 nullable=1 is_null=0 */
### @3='Wow' /* VARSTRING(60) meta=60 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2=4 /* INT meta=0 nullable=1 is_null=0 */
### @3='Wow' /* VARSTRING(60) meta=60 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=5 /* INT meta=0 nullable=1 is_null=0 */
### @2=6 /* INT meta=0 nullable=1 is_null=0 */
diff --git a/mysql-test/r/mysqlbinlog_row_myisam.result b/mysql-test/r/mysqlbinlog_row_myisam.result
index 7b0112d0a91..c268d20c87d 100644
--- a/mysql-test/r/mysqlbinlog_row_myisam.result
+++ b/mysql-test/r/mysqlbinlog_row_myisam.result
@@ -2253,7 +2253,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -2363,7 +2363,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -2458,7 +2458,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -2555,7 +2555,7 @@ BEGIN
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
@@ -2636,7 +2636,7 @@ BEGIN
### @77=NULL /* TIMESTAMP meta=63233 nullable=1 is_null=1 */
### @78=NULL /* TIMESTAMP meta=63489 nullable=1 is_null=1 */
### @79=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -2731,7 +2731,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -2906,7 +2906,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3081,7 +3081,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
@@ -3256,7 +3256,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3431,7 +3431,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3526,7 +3526,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=b'0' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'0000000000000000000000000000000000000000000000000000000000000000' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3621,7 +3621,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=b'1' /* BIT(1) meta=1 nullable=1 is_null=0 */
### @2=b'1111111111111111111111111111111111111111111111111111111111111111' /* BIT(64) meta=2048 nullable=1 is_null=0 */
@@ -3716,7 +3716,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=NULL /* type=16 meta=1 nullable=1 is_null=1 */
### @2=NULL /* type=16 meta=2048 nullable=1 is_null=1 */
@@ -3898,7 +3898,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -3923,47 +3923,47 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=1 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-04' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-05' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-06' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-07' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:08' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-08' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=8 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:08:09' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-09' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -3982,7 +3982,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -3991,7 +3991,7 @@ BEGIN
### @1='2008:08:11' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=1 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4000,7 +4000,7 @@ BEGIN
### @1='2008:08:12' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4009,7 +4009,7 @@ BEGIN
### @1='2008:08:13' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-04' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4018,7 +4018,7 @@ BEGIN
### @1='2008:08:14' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-04' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-05' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4027,7 +4027,7 @@ BEGIN
### @1='2008:08:15' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-05' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-06' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4036,7 +4036,7 @@ BEGIN
### @1='2008:08:16' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-06' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:08:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-07' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4059,37 +4059,37 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:11' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=1 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:12' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:13' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:14' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-04' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:15' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-05' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:16' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-06' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2008:08:17' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-07' /* VARSTRING(24) meta=24 nullable=1 is_null=0 */
@@ -4271,7 +4271,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -4314,47 +4314,47 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-01' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=11 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:08' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-08' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=18 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1='2008:01:09' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-09' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4373,47 +4373,47 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-01' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=21 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:08' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-08' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=28 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1='2008:02:09' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-09' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4432,47 +4432,47 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t3` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:01' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-01' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=31 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:08' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-08' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=38 /* INT meta=0 nullable=1 is_null=0 */
-### INSERT INTO test.t3
+### INSERT INTO `test`.`t3`
### SET
### @1='2008:03:09' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-09' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4499,7 +4499,7 @@ BEGIN
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4508,7 +4508,7 @@ BEGIN
### @1='2018:01:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4517,7 +4517,7 @@ BEGIN
### @1='2018:01:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4526,7 +4526,7 @@ BEGIN
### @1='2018:01:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4535,7 +4535,7 @@ BEGIN
### @1='2018:01:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4544,7 +4544,7 @@ BEGIN
### @1='2018:01:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1='2008:01:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4553,7 +4553,7 @@ BEGIN
### @1='2018:01:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4562,7 +4562,7 @@ BEGIN
### @1='2028:02:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4571,7 +4571,7 @@ BEGIN
### @1='2028:02:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4580,7 +4580,7 @@ BEGIN
### @1='2028:02:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4589,7 +4589,7 @@ BEGIN
### @1='2028:02:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4598,7 +4598,7 @@ BEGIN
### @1='2028:02:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1='2008:02:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4607,7 +4607,7 @@ BEGIN
### @1='2028:02:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4616,7 +4616,7 @@ BEGIN
### @1='2038:03:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4625,7 +4625,7 @@ BEGIN
### @1='2038:03:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4634,7 +4634,7 @@ BEGIN
### @1='2038:03:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4643,7 +4643,7 @@ BEGIN
### @1='2038:03:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4652,7 +4652,7 @@ BEGIN
### @1='2038:03:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### UPDATE test.t3
+### UPDATE `test`.`t3`
### WHERE
### @1='2008:03:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4683,92 +4683,92 @@ BEGIN
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1='2018:01:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-01-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1='2028:02:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-02-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=7 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:02' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-02' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=2 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:03' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-03' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=3 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:04' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-04' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=4 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:05' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-05' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=5 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:06' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-06' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
### @3=6 /* INT meta=0 nullable=1 is_null=0 */
-### DELETE FROM test.t3
+### DELETE FROM `test`.`t3`
### WHERE
### @1='2038:03:07' /* DATE meta=0 nullable=1 is_null=0 */
### @2='VARCHAR-03-07' /* VARSTRING(255) meta=255 nullable=1 is_null=0 */
@@ -4842,7 +4842,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -4867,17 +4867,17 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2=2 /* INT meta=0 nullable=1 is_null=0 */
### @3='Wow' /* VARSTRING(60) meta=60 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2=4 /* INT meta=0 nullable=1 is_null=0 */
### @3='Wow' /* VARSTRING(60) meta=60 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=5 /* INT meta=0 nullable=1 is_null=0 */
### @2=6 /* INT meta=0 nullable=1 is_null=0 */
diff --git a/mysql-test/r/mysqlbinlog_row_trans.result b/mysql-test/r/mysqlbinlog_row_trans.result
index 5c96db7d19b..5d08a1095a9 100644
--- a/mysql-test/r/mysqlbinlog_row_trans.result
+++ b/mysql-test/r/mysqlbinlog_row_trans.result
@@ -132,7 +132,7 @@ DELIMITER /*!*/;
ROLLBACK/*!*/;
# at #
#010909 4:46:40 server id 1 end_log_pos # Query thread_id=# exec_time=# error_code=0
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=#/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -164,15 +164,15 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -180,21 +180,21 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
### SET
### @1=11 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
### SET
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -205,7 +205,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -231,15 +231,15 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -257,21 +257,21 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
### SET
### @1=11 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
### SET
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -292,7 +292,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -310,15 +310,15 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### INSERT INTO test.t1
+### INSERT INTO `test`.`t1`
### SET
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -326,21 +326,21 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
### SET
### @1=11 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
### SET
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### UPDATE test.t1
+### UPDATE `test`.`t1`
### WHERE
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -351,7 +351,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t1` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t1
+### DELETE FROM `test`.`t1`
### WHERE
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -377,15 +377,15 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Write_rows: table id # flags: STMT_END_F
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### INSERT INTO test.t2
+### INSERT INTO `test`.`t2`
### SET
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -403,21 +403,21 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Update_rows: table id # flags: STMT_END_F
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1=1 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
### SET
### @1=11 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-1' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1=2 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
### SET
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
-### UPDATE test.t2
+### UPDATE `test`.`t2`
### WHERE
### @1=3 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-3' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
@@ -438,7 +438,7 @@ BEGIN
# at #
#010909 4:46:40 server id 1 end_log_pos # Table_map: `test`.`t2` mapped to number #
#010909 4:46:40 server id 1 end_log_pos # Delete_rows: table id # flags: STMT_END_F
-### DELETE FROM test.t2
+### DELETE FROM `test`.`t2`
### WHERE
### @1=12 /* INT meta=0 nullable=1 is_null=0 */
### @2='varchar-2' /* VARSTRING(20) meta=20 nullable=1 is_null=0 */
diff --git a/mysql-test/r/user_var-binlog.result b/mysql-test/r/user_var-binlog.result
index 251d0b39098..68d2364986d 100644
--- a/mysql-test/r/user_var-binlog.result
+++ b/mysql-test/r/user_var-binlog.result
@@ -34,7 +34,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET @`a b`:=_latin1 0x68656C6C6F COLLATE `latin1_swedish_ci`/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=10000/*!*/;
INSERT INTO t1 VALUES(@`a b`)
/*!*/;
diff --git a/mysql-test/suite/binlog/r/binlog_base64_flag.result b/mysql-test/suite/binlog/r/binlog_base64_flag.result
index 9a9f328f2b5..dfca5b2a1e9 100644
--- a/mysql-test/suite/binlog/r/binlog_base64_flag.result
+++ b/mysql-test/suite/binlog/r/binlog_base64_flag.result
@@ -35,7 +35,7 @@ DELIMITER /*!*/;
# at 4
<#>ROLLBACK/*!*/;
# at 102
-<#>use test/*!*/;
+<#>use `test`/*!*/;
SET TIMESTAMP=1196959712/*!*/;
<#>SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=1, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
SET @@session.sql_mode=0/*!*/;
diff --git a/mysql-test/suite/binlog/r/binlog_database.result b/mysql-test/suite/binlog/r/binlog_database.result
index 0eaed3c97d7..99066d632ac 100644
--- a/mysql-test/suite/binlog/r/binlog_database.result
+++ b/mysql-test/suite/binlog/r/binlog_database.result
@@ -58,7 +58,7 @@ Tables_in_db1
t2
show binlog events from <binlog_start>;
Log_name Pos Event_type Server_id End_log_pos Info
-master-bin.000001 # Query # # use `db1`; drop table `t1`
+master-bin.000001 # Query # # use `db1`; DROP TABLE `t1`
DROP TABLE t3;
DROP DATABASE db1;
set binlog_format=mixed;
@@ -121,7 +121,7 @@ Tables_in_db1
t2
show binlog events from <binlog_start>;
Log_name Pos Event_type Server_id End_log_pos Info
-master-bin.000001 # Query # # use `db1`; drop table `t1`
+master-bin.000001 # Query # # use `db1`; DROP TABLE `t1`
DROP TABLE t3;
DROP DATABASE db1;
set binlog_format=row;
@@ -185,7 +185,7 @@ Tables_in_db1
t2
show binlog events from <binlog_start>;
Log_name Pos Event_type Server_id End_log_pos Info
-master-bin.000001 # Query # # use `db1`; drop table `t1`
+master-bin.000001 # Query # # use `db1`; DROP TABLE `t1`
DROP TABLE t3;
DROP DATABASE db1;
show databases;
diff --git a/mysql-test/suite/binlog/r/binlog_row_mysqlbinlog_verbose.result b/mysql-test/suite/binlog/r/binlog_row_mysqlbinlog_verbose.result
index 2687b21213a..cbb739a9c48 100644
--- a/mysql-test/suite/binlog/r/binlog_row_mysqlbinlog_verbose.result
+++ b/mysql-test/suite/binlog/r/binlog_row_mysqlbinlog_verbose.result
@@ -1,152 +1,152 @@
Verbose statements from : write-partial-row.binlog
select replace(txt,'\r', '') as stmt from raw_binlog_rows where txt like '###%';
stmt
-### INSERT INTO mysql.ndb_apply_status
+### INSERT INTO `mysql`.`ndb_apply_status`
### SET
### @1=1
### @2=25769803786
### @3=''
### @4=0
### @5=0
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=3
### @2=3
### @3=3
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=1
### @2=1
### @3=1
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=2
### @2=2
### @3=2
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=4
### @2=4
### @3=4
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=4
### @3=40
-### DELETE FROM test.ba
+### DELETE FROM `test`.`ba`
### WHERE
### @1=2
drop table raw_binlog_rows;
Verbose statements from : write-full-row.binlog
select replace(txt,'\r', '') as stmt from raw_binlog_rows where txt like '###%';
stmt
-### INSERT INTO mysql.ndb_apply_status
+### INSERT INTO `mysql`.`ndb_apply_status`
### SET
### @1=2
### @2=25769803786
### @3=''
### @4=0
### @5=0
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=3
### @2=3
### @3=3
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=1
### @2=1
### @3=1
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=2
### @2=2
### @3=2
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=4
### @2=4
### @3=4
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=4
### @2=4
### @3=40
-### DELETE FROM test.ba
+### DELETE FROM `test`.`ba`
### WHERE
### @1=2
drop table raw_binlog_rows;
Verbose statements from : update-partial-row.binlog
select replace(txt,'\r', '') as stmt from raw_binlog_rows where txt like '###%';
stmt
-### INSERT INTO mysql.ndb_apply_status
+### INSERT INTO `mysql`.`ndb_apply_status`
### SET
### @1=3
### @2=25769803786
### @3=''
### @4=0
### @5=0
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=3
### @2=3
### @3=3
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=1
### @2=1
### @3=1
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=2
### @2=2
### @3=2
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=4
### @2=4
### @3=4
-### UPDATE test.ba
+### UPDATE `test`.`ba`
### WHERE
### @1=4
### @3=4
### SET
### @1=4
### @3=40
-### DELETE FROM test.ba
+### DELETE FROM `test`.`ba`
### WHERE
### @1=2
drop table raw_binlog_rows;
Verbose statements from : update-full-row.binlog
select replace(txt,'\r', '') as stmt from raw_binlog_rows where txt like '###%';
stmt
-### INSERT INTO mysql.ndb_apply_status
+### INSERT INTO `mysql`.`ndb_apply_status`
### SET
### @1=4
### @2=25769803786
### @3=''
### @4=0
### @5=0
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=3
### @2=3
### @3=3
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=1
### @2=1
### @3=1
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=2
### @2=2
### @3=2
-### INSERT INTO test.ba
+### INSERT INTO `test`.`ba`
### SET
### @1=4
### @2=4
### @3=4
-### UPDATE test.ba
+### UPDATE `test`.`ba`
### WHERE
### @1=4
### @2=4
@@ -155,7 +155,7 @@ stmt
### @1=4
### @2=4
### @3=40
-### DELETE FROM test.ba
+### DELETE FROM `test`.`ba`
### WHERE
### @1=2
drop table raw_binlog_rows;
diff --git a/mysql-test/suite/binlog/r/binlog_stm_ctype_ucs.result b/mysql-test/suite/binlog/r/binlog_stm_ctype_ucs.result
index 4bdafb609a7..3207b9c2180 100644
--- a/mysql-test/suite/binlog/r/binlog_stm_ctype_ucs.result
+++ b/mysql-test/suite/binlog/r/binlog_stm_ctype_ucs.result
@@ -26,7 +26,7 @@ SET @@session.collation_database=DEFAULT/*!*/;
BEGIN
/*!*/;
SET @`v`:=_ucs2 0x006100620063 COLLATE `ucs2_general_ci`/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=10000/*!*/;
insert into t2 values (@v)
/*!*/;
diff --git a/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result b/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result
index 9e3577e1d5c..1a4d5c7574d 100644
--- a/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result
+++ b/mysql-test/suite/rpl/r/rpl_row_mysqlbinlog.result
@@ -154,7 +154,7 @@ c1 c3 c4 c5
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -176,7 +176,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -287,7 +287,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
@@ -318,7 +318,7 @@ ROLLBACK /* added by mysqlbinlog */;
/*!50003 SET @OLD_COMPLETION_TYPE=@@COMPLETION_TYPE,COMPLETION_TYPE=0*/;
DELIMITER /*!*/;
ROLLBACK/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=1000000000/*!*/;
SET @@session.pseudo_thread_id=999999999/*!*/;
SET @@session.foreign_key_checks=1, @@session.sql_auto_is_null=0, @@session.unique_checks=1, @@session.autocommit=1/*!*/;
diff --git a/mysql-test/suite/rpl/r/rpl_sp.result b/mysql-test/suite/rpl/r/rpl_sp.result
index 4b9e768861d..8a2a88a8c90 100644
--- a/mysql-test/suite/rpl/r/rpl_sp.result
+++ b/mysql-test/suite/rpl/r/rpl_sp.result
@@ -670,7 +670,7 @@ drop database if exists mysqltest1
SET TIMESTAMP=t/*!*/;
create database mysqltest1
/*!*/;
-use mysqltest1/*!*/;
+use `mysqltest1`/*!*/;
SET TIMESTAMP=t/*!*/;
create table t1 (a varchar(100))
/*!*/;
@@ -1015,7 +1015,7 @@ drop database mysqltest1
SET TIMESTAMP=t/*!*/;
drop user "zedjzlcsjhd"@127.0.0.1
/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=t/*!*/;
drop function if exists f1
/*!*/;
@@ -1112,7 +1112,7 @@ create database mysqltest
SET TIMESTAMP=t/*!*/;
create database mysqltest2
/*!*/;
-use mysqltest2/*!*/;
+use `mysqltest2`/*!*/;
SET TIMESTAMP=t/*!*/;
create table t ( t integer )
/*!*/;
@@ -1139,7 +1139,7 @@ end
SET TIMESTAMP=t/*!*/;
BEGIN
/*!*/;
-use mysqltest/*!*/;
+use `mysqltest`/*!*/;
SET TIMESTAMP=t/*!*/;
SELECT `mysqltest2`.`f1`()
/*!*/;
@@ -1152,14 +1152,14 @@ drop database mysqltest
SET TIMESTAMP=t/*!*/;
drop database mysqltest2
/*!*/;
-use test/*!*/;
+use `test`/*!*/;
SET TIMESTAMP=t/*!*/;
CREATE DEFINER=`root`@`localhost` PROCEDURE `mysqltestbug36570_p1`()
begin
select 1;
end
/*!*/;
-use mysql/*!*/;
+use `mysql`/*!*/;
SET TIMESTAMP=t/*!*/;
CREATE DEFINER=`root`@`localhost` PROCEDURE `test`.` mysqltestbug36570_p2`( a int)
`label`:
diff --git a/sql/ha_ndbcluster_binlog.cc b/sql/ha_ndbcluster_binlog.cc
index 040b5778dbd..0f037040902 100644
--- a/sql/ha_ndbcluster_binlog.cc
+++ b/sql/ha_ndbcluster_binlog.cc
@@ -25,6 +25,7 @@
#include "rpl_injector.h"
#include "rpl_filter.h"
#include "slave.h"
+#include "log_event.h"
#include "ha_ndbcluster_binlog.h"
#include "NdbDictionary.hpp"
#include "ndb_cluster_connection.hpp"
@@ -1297,6 +1298,11 @@ int ndbcluster_log_schema_op(THD *thd, NDB_SHARE *share,
}
char tmp_buf2[FN_REFLEN];
+ char quoted_table1[2 + 2 * FN_REFLEN + 1];
+ char quoted_db1[2 + 2 * FN_REFLEN + 1];
+ char quoted_db2[2 + 2 * FN_REFLEN + 1];
+ char quoted_table2[2 + 2 * FN_REFLEN + 1];
+ int id_length= 0;
const char *type_str;
switch (type)
{
@@ -1306,16 +1312,31 @@ int ndbcluster_log_schema_op(THD *thd, NDB_SHARE *share,
DBUG_RETURN(0);
/* redo the drop table query as is may contain several tables */
query= tmp_buf2;
- query_length= (uint) (strxmov(tmp_buf2, "drop table `",
- table_name, "`", NullS) - tmp_buf2);
+ id_length= my_strmov_quoted_identifier (thd, (char *) quoted_table1,
+ table_name, 0);
+ quoted_table1[id_length]= '\0';
+ query_length= (uint) (strxmov(tmp_buf2, "drop table ",
+ quoted_table1, NullS) - tmp_buf2);
type_str= "drop table";
break;
case SOT_RENAME_TABLE:
/* redo the rename table query as is may contain several tables */
query= tmp_buf2;
- query_length= (uint) (strxmov(tmp_buf2, "rename table `",
- db, ".", table_name, "` to `",
- new_db, ".", new_table_name, "`", NullS) - tmp_buf2);
+ id_length= my_strmov_quoted_identifier (thd, (char *) quoted_db1,
+ db, 0);
+ quoted_db1[id_length]= '\0';
+ id_length= my_strmov_quoted_identifier (thd, (char *) quoted_table1,
+ table_name, 0);
+ quoted_table1[id_length]= '\0';
+ id_length= my_strmov_quoted_identifier (thd, (char *) quoted_db2,
+ new_db, 0);
+ quoted_db2[id_length]= '\0';
+ id_length= my_strmov_quoted_identifier (thd, (char *) quoted_table2,
+ new_table_name, 0);
+ quoted_table2[id_length]= '\0';
+ query_length= (uint) (strxmov(tmp_buf2, "rename table ",
+ quoted_db1, ".", quoted_table_1, " to ",
+ quoted_db2, ".", quoted_table2, NullS) - tmp_buf2);
type_str= "rename table";
break;
case SOT_CREATE_TABLE:
diff --git a/sql/log.cc b/sql/log.cc
index 65923eddce0..43db481b7cc 100644
--- a/sql/log.cc
+++ b/sql/log.cc
@@ -39,6 +39,7 @@
#include "rpl_rli.h"
#include "sql_audit.h"
+#include "sql_show.h"
#include <my_dir.h>
#include <stdarg.h>
#include <m_ctype.h> // For test_if_number
@@ -2016,17 +2017,24 @@ static int binlog_savepoint_set(handlerton *hton, THD *thd, void *sv)
DBUG_ENTER("binlog_savepoint_set");
binlog_trans_log_savepos(thd, (my_off_t*) sv);
+
+ // buffer to store quoted identifier
+ char* buffer= (char *)my_malloc(sizeof("SAVEPOINT ")+ 1 + NAME_LEN * 2 + 2,
+ MYF(0));
+ String log_query(buffer, sizeof(buffer), system_charset_info);
+ log_query.length(0);
+
/* Write it to the binary log */
- String log_query;
- if (log_query.append(STRING_WITH_LEN("SAVEPOINT ")) ||
- log_query.append("`") ||
- log_query.append(thd->lex->ident.str, thd->lex->ident.length) ||
- log_query.append("`"))
+ if (log_query.append(STRING_WITH_LEN("SAVEPOINT ")))
DBUG_RETURN(1);
+ else
+ append_identifier(thd, &log_query, thd->lex->ident.str,
+ thd->lex->ident.length);
int errcode= query_error_code(thd, thd->killed == THD::NOT_KILLED);
Query_log_event qinfo(thd, log_query.c_ptr_safe(), log_query.length(),
TRUE, FALSE, TRUE, errcode);
+ my_free(buffer);
DBUG_RETURN(mysql_bin_log.write(&qinfo));
}
@@ -2042,15 +2050,20 @@ static int binlog_savepoint_rollback(handlerton *hton, THD *thd, void *sv)
if (unlikely(trans_has_updated_non_trans_table(thd) ||
(thd->variables.option_bits & OPTION_KEEP_LOG)))
{
- String log_query;
- if (log_query.append(STRING_WITH_LEN("ROLLBACK TO ")) ||
- log_query.append("`") ||
- log_query.append(thd->lex->ident.str, thd->lex->ident.length) ||
- log_query.append("`"))
+ // buffer to store rollback query with quoted identifier
+ char* buffer= (char *)my_malloc(12 + 1 + NAME_LEN * 2 + 2, MYF(0));
+ String log_query(buffer, sizeof(buffer), system_charset_info);
+ log_query.length(0);
+
+ if (log_query.append(STRING_WITH_LEN("ROLLBACK TO ")))
DBUG_RETURN(1);
+ else
+ append_identifier(thd, &log_query, thd->lex->ident.str,
+ thd->lex->ident.length);
int errcode= query_error_code(thd, thd->killed == THD::NOT_KILLED);
Query_log_event qinfo(thd, log_query.c_ptr_safe(), log_query.length(),
TRUE, FALSE, TRUE, errcode);
+ my_free(buffer);
DBUG_RETURN(mysql_bin_log.write(&qinfo));
}
binlog_trans_log_truncate(thd, *(my_off_t*)sv);
diff --git a/sql/log_event.cc b/sql/log_event.cc
index 73c2342b6fa..25a552bced9 100644
--- a/sql/log_event.cc
+++ b/sql/log_event.cc
@@ -45,6 +45,7 @@
#include "rpl_record.h"
#include "transaction.h"
#include <my_dir.h>
+#include "sql_show.h" // append_identifier
#endif /* MYSQL_CLIENT */
@@ -1963,6 +1964,10 @@ Rows_log_event::print_verbose_one_row(IO_CACHE *file, table_def *td,
void Rows_log_event::print_verbose(IO_CACHE *file,
PRINT_EVENT_INFO *print_event_info)
{
+ // Quoted length of the identifier can be twice the original length
+ char quoted_db[1 + NAME_LEN * 2 + 2];
+ char quoted_table[1 + NAME_LEN * 2 + 2];
+ int quoted_db_len, quoted_table_len;
Table_map_log_event *map;
table_def *td;
const char *sql_command, *sql_clause1, *sql_clause2;
@@ -1999,9 +2004,23 @@ void Rows_log_event::print_verbose(IO_CACHE *file,
for (const uchar *value= m_rows_buf; value < m_rows_end; )
{
size_t length;
+#ifdef MYSQL_SERVER
+ quoted_db_len= my_strmov_quoted_identifier(this->thd, (char *) quoted_db,
+ map->get_db_name(), 0);
+ quoted_table_len= my_strmov_quoted_identifier(this->thd,
+ (char *) quoted_table,
+ map->get_table_name(), 0);
+#else
+ quoted_db_len= my_strmov_quoted_identifier((char *) quoted_db,
+ map->get_db_name());
+ quoted_table_len= my_strmov_quoted_identifier((char *) quoted_table,
+ map->get_table_name());
+#endif
+ quoted_db[quoted_db_len]= '\0';
+ quoted_table[quoted_table_len]= '\0';
my_b_printf(file, "### %s %s.%s\n",
sql_command,
- map->get_db_name(), map->get_table_name());
+ quoted_db, quoted_table);
/* Print the first image */
if (!(length= print_verbose_one_row(file, td, print_event_info,
&m_cols, value,
@@ -2160,24 +2179,20 @@ Log_event::continue_group(Relay_log_info *rli)
void Query_log_event::pack_info(Protocol *protocol)
{
// TODO: show the catalog ??
- char *buf, *pos;
- if (!(buf= (char*) my_malloc(9 + db_len + q_len, MYF(MY_WME))))
- return;
- pos= buf;
+ String temp_buf;
+ // Add use `DB` to the string if required
if (!(flags & LOG_EVENT_SUPPRESS_USE_F)
&& db && db_len)
{
- pos= strmov(buf, "use `");
- memcpy(pos, db, db_len);
- pos= strmov(pos+db_len, "`; ");
+ temp_buf.append("use ");
+ append_identifier(this->thd, &temp_buf, db, db_len);
+ temp_buf.append("; ");
}
+ // Add the query to the string
if (query && q_len)
- {
- memcpy(pos, query, q_len);
- pos+= q_len;
- }
- protocol->store(buf, pos-buf, &my_charset_bin);
- my_free(buf);
+ temp_buf.append(query);
+ // persist the buffer in protocol
+ protocol->store(temp_buf.ptr(), temp_buf.length(), &my_charset_bin);
}
#endif
@@ -3006,6 +3021,8 @@ void Query_log_event::print_query_header(IO_CACHE* file,
{
// TODO: print the catalog ??
char buff[40],*end; // Enough for SET TIMESTAMP
+ char quoted_id[1+ 2*FN_REFLEN+ 2];
+ int quoted_len= 0;
bool different_db= 1;
uint32 tmp;
@@ -3024,11 +3041,17 @@ void Query_log_event::print_query_header(IO_CACHE* file,
}
else if (db)
{
+#ifdef MYSQL_SERVER
+ quoted_len= my_strmov_quoted_identifier(this->thd, (char*)quoted_id, db, 0);
+#else
+ quoted_len= my_strmov_quoted_identifier((char*)quoted_id, db);
+#endif
+ quoted_id[quoted_len]= '\0';
different_db= memcmp(print_event_info->db, db, db_len + 1);
if (different_db)
memcpy(print_event_info->db, db, db_len + 1);
if (db[0] && different_db)
- my_b_printf(file, "use %s%s\n", db, print_event_info->delimiter);
+ my_b_printf(file, "use %s%s\n", quoted_id, print_event_info->delimiter);
}
end=int10_to_str((long) when, strmov(buff,"SET TIMESTAMP="),10);
@@ -4318,7 +4341,8 @@ void Format_description_log_event::calc_server_version_split()
uint Load_log_event::get_query_buffer_length()
{
return
- 5 + db_len + 3 + // "use DB; "
+ //the DB name may double if we escape the quote character
+ 5 + 2*db_len + 3 +
18 + fname_len + 2 + // "LOAD DATA INFILE 'file''"
11 + // "CONCURRENT "
7 + // LOCAL
@@ -4337,13 +4361,21 @@ uint Load_log_event::get_query_buffer_length()
void Load_log_event::print_query(bool need_db, const char *cs, char *buf,
char **end, char **fn_start, char **fn_end)
{
+ char quoted_id[1 + NAME_LEN * 2 + 2];//quoted length
+ int quoted_id_len= 0;
char *pos= buf;
if (need_db && db && db_len)
{
- pos= strmov(pos, "use `");
- memcpy(pos, db, db_len);
- pos= strmov(pos+db_len, "`; ");
+ pos= strmov(pos, "use ");
+#ifdef MYSQL_SERVER
+ quoted_id_len= my_strmov_quoted_identifier(this->thd, (char *) quoted_id,
+ db, 0);
+#else
+ quoted_id_len= my_strmov_quoted_identifier((char *) quoted_id, db);
+#endif
+ pos+= quoted_id_len;
+ pos= strmov(pos, "; ");
}
pos= strmov(pos, "LOAD DATA ");
@@ -4370,17 +4402,15 @@ void Load_log_event::print_query(bool need_db, const char *cs, char *buf,
if (fn_end)
*fn_end= pos;
- pos= strmov(pos ," TABLE `");
+ pos= strmov(pos ," TABLE ");
memcpy(pos, table_name, table_name_len);
pos+= table_name_len;
if (cs != NULL)
{
- pos= strmov(pos ,"` CHARACTER SET ");
+ pos= strmov(pos ," CHARACTER SET ");
pos= strmov(pos , cs);
}
- else
- pos= strmov(pos, "`");
/* We have to create all optional fields as the default is not empty */
pos= strmov(pos, " FIELDS TERMINATED BY ");
@@ -4420,9 +4450,9 @@ void Load_log_event::print_query(bool need_db, const char *cs, char *buf,
*pos++= ' ';
*pos++= ',';
}
- memcpy(pos, field, field_lens[i]);
- pos+= field_lens[i];
- field+= field_lens[i] + 1;
+ quoted_id_len= my_strmov_quoted_identifier(this->thd, quoted_id, field,
+ 0);
+ memcpy(pos, quoted_id, quoted_id_len);
}
*pos++= ')';
}
@@ -4670,6 +4700,8 @@ void Load_log_event::print(FILE* file, PRINT_EVENT_INFO* print_event_info)
void Load_log_event::print(FILE* file_arg, PRINT_EVENT_INFO* print_event_info,
bool commented)
{
+ size_t id_len= 0;
+ char temp_buf[1 + 2*FN_REFLEN + 2];
Write_on_release_cache cache(&print_event_info->head_cache, file_arg);
DBUG_ENTER("Load_log_event::print");
@@ -4695,10 +4727,16 @@ void Load_log_event::print(FILE* file_arg, PRINT_EVENT_INFO* print_event_info,
}
if (db && db[0] && different_db)
- my_b_printf(&cache, "%suse %s%s\n",
- commented ? "# " : "",
- db, print_event_info->delimiter);
-
+ {
+#ifdef MYSQL_SERVER
+ id_len= my_strmov_quoted_identifier(this->thd, temp_buf, db, 0);
+#else
+ id_len= my_strmov_quoted_identifier(temp_buf, db);
+#endif
+ temp_buf[id_len]= '\0';
+ my_b_printf(&cache, "%suse %s%s\n",
+ commented ? "# " : "", temp_buf, print_event_info->delimiter);
+ }
if (flags & LOG_EVENT_THREAD_SPECIFIC_F)
my_b_printf(&cache,"%sSET @@session.pseudo_thread_id=%lu%s\n",
commented ? "# " : "", (ulong)thread_id,
@@ -4713,8 +4751,14 @@ void Load_log_event::print(FILE* file_arg, PRINT_EVENT_INFO* print_event_info,
my_b_printf(&cache,"REPLACE ");
else if (sql_ex.opt_flags & IGNORE_FLAG)
my_b_printf(&cache,"IGNORE ");
-
- my_b_printf(&cache, "INTO TABLE `%s`", table_name);
+
+#ifdef MYSQL_SERVER
+ id_len= my_strmov_quoted_identifier(this->thd, temp_buf, table_name, 0);
+#else
+ id_len= my_strmov_quoted_identifier(temp_buf, table_name);
+#endif
+ temp_buf[id_len]= '\0';
+ my_b_printf(&cache, "INTO TABLE %s", temp_buf);
my_b_printf(&cache, " FIELDS TERMINATED BY ");
pretty_print_str(&cache, sql_ex.field_term, sql_ex.field_term_len);
@@ -4747,7 +4791,9 @@ void Load_log_event::print(FILE* file_arg, PRINT_EVENT_INFO* print_event_info,
{
if (i)
my_b_printf(&cache, ",");
- my_b_printf(&cache, "%s", field);
+ id_len= my_strmov_quoted_identifier((char *) temp_buf, field);
+ temp_buf[id_len]= '\0';
+ my_b_printf(&cache, "%s", temp_buf);
field += field_lens[i] + 1;
}
@@ -5684,7 +5730,10 @@ Xid_log_event::do_shall_skip(Relay_log_info *rli)
void User_var_log_event::pack_info(Protocol* protocol)
{
char *buf= 0;
- uint val_offset= 4 + name_len;
+ char quoted_id[1 + FN_REFLEN * 2 + 2];// quoted identifier
+ int id_len= my_strmov_quoted_identifier(this->thd, quoted_id, name, 0);
+ quoted_id[id_len]= '\0';
+ uint val_offset= 2 + id_len;
uint event_len= val_offset;
if (is_null)
@@ -5753,10 +5802,8 @@ void User_var_log_event::pack_info(Protocol* protocol)
}
}
buf[0]= '@';
- buf[1]= '`';
- memcpy(buf+2, name, name_len);
- buf[2+name_len]= '`';
- buf[3+name_len]= '=';
+ memcpy(buf + 1, quoted_id, id_len);
+ buf[1 + id_len]= '=';
protocol->store(buf, event_len, &my_charset_bin);
my_free(buf);
}
@@ -5893,6 +5940,8 @@ bool User_var_log_event::write(IO_CACHE* file)
#ifdef MYSQL_CLIENT
void User_var_log_event::print(FILE* file, PRINT_EVENT_INFO* print_event_info)
{
+ char quoted_id[1 + NAME_LEN * 2 + 2];// quoted length of the identifier
+ int quoted_len= 0;
Write_on_release_cache cache(&print_event_info->head_cache, file,
Write_on_release_cache::FLUSH_F);
@@ -5902,9 +5951,11 @@ void User_var_log_event::print(FILE* file, PRINT_EVENT_INFO* print_event_info)
my_b_printf(&cache, "\tUser_var\n");
}
- my_b_printf(&cache, "SET @`");
- my_b_write(&cache, (uchar*) name, (uint) (name_len));
- my_b_printf(&cache, "`");
+ my_b_printf(&cache, "SET @");
+ quoted_len= my_strmov_quoted_identifier((char *) quoted_id,
+ (const char *) name);
+ quoted_id[quoted_len]= '\0';
+ my_b_write(&cache, (uchar*) quoted_id, (uint) quoted_len);
if (is_null)
{
@@ -7212,14 +7263,23 @@ void Execute_load_query_log_event::print(FILE* file,
void Execute_load_query_log_event::pack_info(Protocol *protocol)
{
char *buf, *pos;
- if (!(buf= (char*) my_malloc(9 + db_len + q_len + 10 + 21, MYF(MY_WME))))
+ if (!(buf= (char*) my_malloc(9 + (db_len * 2) + 2 + q_len + 10 + 21,
+ MYF(MY_WME))))
return;
pos= buf;
if (db && db_len)
{
- pos= strmov(buf, "use `");
- memcpy(pos, db, db_len);
- pos= strmov(pos+db_len, "`; ");
+ /*
+ Statically allocates room to store '\0' and an identifier
+ that may have NAME_LEN * 2 due to quoting and there are
+ two quoting characters that wrap them.
+ */
+ char quoted_db[1 + NAME_LEN * 2 + 2];// quoted length of the identifier
+ size_t size= 0;
+ size= my_strmov_quoted_identifier(this->thd, quoted_db, db, 0);
+ pos= strmov(buf, "use ");
+ memcpy(pos, quoted_db, size);
+ pos= strmov(pos + size, "; ");
}
if (query && q_len)
{
@@ -10186,3 +10246,62 @@ Heartbeat_log_event::Heartbeat_log_event(const char* buf, uint event_len,
log_ident= buf + header_size;
}
#endif
+
+#ifdef MYSQL_SERVER
+/*
+ This is a utility function that adds a quoted identifier into the a buffer.
+ This also escapes any existance of the quote string inside the identifier.
+
+ SYNOPSIS
+ my_strmov_quoted_identifier
+ thd thread handler
+ buffer target buffer
+ identifier the identifier to be quoted
+ length length of the identifier
+*/
+size_t my_strmov_quoted_identifier(THD* thd, char *buffer,
+ const char* identifier,
+ uint length)
+{
+ int q= thd ? get_quote_char_for_identifier(thd, identifier, length) : '`';
+ return my_strmov_quoted_identifier_helper(q, buffer, identifier, length);
+}
+#else
+size_t my_strmov_quoted_identifier(char *buffer, const char* identifier)
+{
+ int q= '`';
+ return my_strmov_quoted_identifier_helper(q, buffer, identifier, 0);
+}
+
+#endif
+
+size_t my_strmov_quoted_identifier_helper(int q, char *buffer,
+ const char* identifier,
+ uint length)
+{
+ size_t written= 0;
+ char quote_char;
+ uint id_length= (length) ? length : strlen(identifier);
+
+ if (q == EOF)
+ {
+ (void *) strncpy(buffer, identifier, id_length);
+ return id_length;
+ }
+ quote_char= (char) q;
+ *buffer++= quote_char;
+ written++;
+ while (id_length--)
+ {
+ if (*identifier == quote_char)
+ {
+ *buffer++= quote_char;
+ written++;
+ }
+ *buffer++= *identifier++;
+ written++;
+ }
+ *buffer++= quote_char;
+ return ++written;
+}
+
diff --git a/sql/log_event.h b/sql/log_event.h
index badaf2eaa79..ac7aa7e9453 100644
--- a/sql/log_event.h
+++ b/sql/log_event.h
@@ -4107,6 +4107,23 @@ bool slave_execute_deferred_events(THD *thd);
int append_query_string(THD *thd, CHARSET_INFO *csinfo,
String const *from, String *to);
+
+#ifdef MYSQL_SERVER
+/*
+ This is an utility function that adds a quoted identifier into the a buffer.
+ This also escapes any existance of the quote string inside the identifier.
+ */
+size_t my_strmov_quoted_identifier(THD *thd, char *buffer,
+ const char* identifier,
+ uint length);
+#else
+size_t my_strmov_quoted_identifier(char *buffer, const char* identifier);
+#endif
+size_t my_strmov_quoted_identifier_helper(int q, char *buffer,
+ const char* identifier,
+ uint length);
+
+
/**
@} (end of group Replication)
*/
diff --git a/sql/sql_base.cc b/sql/sql_base.cc
index a7d04f12341..7b1893eaf43 100644
--- a/sql/sql_base.cc
+++ b/sql/sql_base.cc
@@ -3831,24 +3831,19 @@ static bool open_table_entry_fini(THD *thd, TABLE_SHARE *share, TABLE *entry)
entry->file->implicit_emptied= 0;
if (mysql_bin_log.is_open())
{
- char *query, *end;
- uint query_buf_size= 20 + share->db.length + share->table_name.length +1;
- if ((query= (char*) my_malloc(query_buf_size,MYF(MY_WME))))
- {
- /* this DELETE FROM is needed even with row-based binlogging */
- end = strxmov(strmov(query, "DELETE FROM `"),
- share->db.str,"`.`",share->table_name.str,"`", NullS);
- int errcode= query_error_code(thd, TRUE);
- if (thd->binlog_query(THD::STMT_QUERY_TYPE,
- query, (ulong)(end-query),
- FALSE, FALSE, FALSE, errcode))
- {
- my_free(query);
- return TRUE;
- }
- my_free(query);
- }
- else
+ bool error= false;
+ String temp_buf;
+ error= temp_buf.append("DELETE FROM ");
+ append_identifier(thd, &temp_buf, share->db.str, strlen(share->db.str));
+ error= temp_buf.append(".");
+ append_identifier(thd, &temp_buf, share->table_name.str,
+ strlen(share->table_name.str));
+ int errcode= query_error_code(thd, TRUE);
+ if (thd->binlog_query(THD::STMT_QUERY_TYPE,
+ temp_buf.c_ptr_safe(), temp_buf.length(),
+ FALSE, FALSE, FALSE, errcode))
+ return TRUE;
+ if (error)
{
/*
As replication is maybe going to be corrupted, we need to warn the
diff --git a/sql/sql_db.cc b/sql/sql_db.cc
index 99cb8cf4b3a..c0a0a4d5522 100644
--- a/sql/sql_db.cc
+++ b/sql/sql_db.cc
@@ -37,6 +37,7 @@
#include <my_dir.h>
#include <m_ctype.h>
#include "log.h"
+#include "log_event.h"
#ifdef __WIN__
#include <direct.h>
#endif
@@ -619,12 +620,17 @@ not_silent:
{
char *query;
uint query_length;
+ char db_name_quoted[2 * FN_REFLEN + sizeof("create database ") + 2];
+ int id_len= 0;
if (!thd->query()) // Only in replication
{
- query= tmp_query;
- query_length= (uint) (strxmov(tmp_query,"create database `",
- db, "`", NullS) - tmp_query);
+ id_len= my_strmov_quoted_identifier(thd, (char *) db_name_quoted, db,
+ 0);
+ db_name_quoted[id_len]= '\0';
+ query= tmp_query;
+ query_length= (uint) (strxmov(tmp_query,"create database ",
+ db_name_quoted, NullS) - tmp_query);
}
else
{
@@ -761,7 +767,7 @@ bool mysql_rm_db(THD *thd,char *db,bool if_exists, bool silent)
{
ulong deleted_tables= 0;
bool error= true;
- char path[FN_REFLEN+16];
+ char path[2 * FN_REFLEN + 16];
MY_DIR *dirp;
uint length;
bool found_other_files= false;
@@ -883,11 +889,16 @@ update_binlog:
{
const char *query;
ulong query_length;
+ // quoted db name + wraping quote
+ char buffer_temp [2 * FN_REFLEN + 2];
+ int id_len= 0;
if (!thd->query())
{
/* The client used the old obsolete mysql_drop_db() call */
query= path;
- query_length= (uint) (strxmov(path, "drop database `", db, "`",
+ id_len= my_strmov_quoted_identifier(thd, buffer_temp, db, strlen(db));
+ buffer_temp[id_len] ='\0';
+ query_length= (uint) (strxmov(path, "DROP DATABASE ", buffer_temp, "",
NullS) - path);
}
else
@@ -925,12 +936,13 @@ update_binlog:
else if (mysql_bin_log.is_open() && !silent)
{
char *query, *query_pos, *query_end, *query_data_start;
+ char temp_identifier[ 2 * FN_REFLEN + 2];
TABLE_LIST *tbl;
- uint db_len;
+ uint db_len, id_length=0;
if (!(query= (char*) thd->alloc(MAX_DROP_TABLE_Q_LEN)))
goto exit; /* not much else we can do */
- query_pos= query_data_start= strmov(query,"drop table ");
+ query_pos= query_data_start= strmov(query,"DROP TABLE ");
query_end= query + MAX_DROP_TABLE_Q_LEN;
db_len= strlen(db);
@@ -963,10 +975,10 @@ update_binlog:
}
query_pos= query_data_start;
}
-
- *query_pos++ = '`';
- query_pos= strmov(query_pos,tbl->table_name);
- *query_pos++ = '`';
+ id_length= my_strmov_quoted_identifier(thd, (char *)temp_identifier,
+ tbl->table_name, 0);
+ temp_identifier[id_length]= '\0';
+ query_pos= strmov(query_pos,(char *)&temp_identifier);
*query_pos++ = ',';
}
diff --git a/sql/sql_load.cc b/sql/sql_load.cc
index 1819102aa34..611c32696ea 100644
--- a/sql/sql_load.cc
+++ b/sql/sql_load.cc
@@ -38,7 +38,7 @@
#include "sql_repl.h"
#include "sp_head.h"
#include "sql_trigger.h"
-
+#include "sql_show.h"
class XML_TAG {
public:
int level;
@@ -678,23 +678,20 @@ static bool write_execute_load_query_log_event(THD *thd, sql_exchange* ex,
const char *tbl= table_name_arg;
const char *tdb= (thd->db != NULL ? thd->db : db_arg);
String string_buf;
-
- if (!thd->db || strcmp(db_arg, thd->db))
+ if (!thd->db || strcmp(db_arg, thd->db))
{
/*
- If used database differs from table's database,
- prefix table name with database name so that it
+ If used database differs from table's database,
+ prefix table name with database name so that it
becomes a FQ name.
*/
string_buf.set_charset(system_charset_info);
- string_buf.append(db_arg);
- string_buf.append("`");
+ append_identifier(thd, &string_buf, db_arg, strlen(db_arg));
string_buf.append(".");
- string_buf.append("`");
- string_buf.append(table_name_arg);
- tbl= string_buf.c_ptr_safe();
}
-
+ append_identifier(thd, &string_buf, table_name_arg,
+ strlen(table_name_arg));
+ tbl= string_buf.c_ptr_safe();
Load_log_event lle(thd, ex, tdb, tbl, fv, is_concurrent,
duplicates, ignore, transactional_table);
@@ -719,11 +716,7 @@ static bool write_execute_load_query_log_event(THD *thd, sql_exchange* ex,
if (n++)
pfields.append(", ");
if (item->type() == Item::FIELD_ITEM)
- {
- pfields.append("`");
- pfields.append(item->name);
- pfields.append("`");
- }
+ append_identifier(thd, &pfields, item->name, strlen(item->name));
else
item->print(&pfields, QT_ORDINARY);
}
@@ -743,9 +736,7 @@ static bool write_execute_load_query_log_event(THD *thd, sql_exchange* ex,
val= lv++;
if (n++)
pfields.append(", ");
- pfields.append("`");
- pfields.append(item->name);
- pfields.append("`");
+ append_identifier(thd, &pfields, item->name, strlen(item->name));
pfields.append(val->name);
}
}
diff --git a/sql/sql_show.cc b/sql/sql_show.cc
index 6c940661763..81e18ccd6c3 100644
--- a/sql/sql_show.cc
+++ b/sql/sql_show.cc
@@ -952,7 +952,8 @@ append_identifier(THD *thd, String *packet, const char *name, uint length)
{
const char *name_end;
char quote_char;
- int q= get_quote_char_for_identifier(thd, name, length);
+ int q;
+ q= thd ? get_quote_char_for_identifier(thd, name, length) : '`';
if (q == EOF)
{
diff --git a/sql/sql_show.h b/sql/sql_show.h
index 8ad9327c08c..406c75d8cbe 100644
--- a/sql/sql_show.h
+++ b/sql/sql_show.h
@@ -89,6 +89,7 @@ int store_create_info(THD *thd, TABLE_LIST *table_list, String *packet,
int view_store_create_info(THD *thd, TABLE_LIST *table, String *buff);
int copy_event_to_schema_table(THD *thd, TABLE *sch_table, TABLE *event_table);
+int get_quote_char_for_identifier(THD *thd, const char *name, uint length);
void append_identifier(THD *thd, String *packet, const char *name,
uint length);
diff --git a/sql/sql_table.cc b/sql/sql_table.cc
index 7d70fa8afd2..b19b265a311 100644
--- a/sql/sql_table.cc
+++ b/sql/sql_table.cc
@@ -2053,6 +2053,7 @@ int mysql_rm_table_no_locks(THD *thd, TABLE_LIST *tables, bool if_exists,
{
bool is_trans;
char *db=table->db;
+ int db_len= table->db_length;
handlerton *table_type;
enum legacy_db_type frm_db_type= DB_TYPE_UNKNOWN;
@@ -2114,14 +2115,14 @@ int mysql_rm_table_no_locks(THD *thd, TABLE_LIST *tables, bool if_exists,
Don't write the database name if it is the current one (or if
thd->db is NULL).
*/
- built_ptr_query->append("`");
if (thd->db == NULL || strcmp(db,thd->db) != 0)
{
- built_ptr_query->append(db);
- built_ptr_query->append("`.`");
+ append_identifier(thd, built_ptr_query, db, db_len);
+ built_ptr_query->append(".");
}
- built_ptr_query->append(table->table_name);
- built_ptr_query->append("`,");
+ append_identifier(thd, built_ptr_query, table->table_name,
+ strlen(table->table_name));
+ built_ptr_query->append(",");
}
/*
This means that a temporary table was droped and as such there
@@ -2180,15 +2181,15 @@ int mysql_rm_table_no_locks(THD *thd, TABLE_LIST *tables, bool if_exists,
Don't write the database name if it is the current one (or if
thd->db is NULL).
*/
- built_query.append("`");
if (thd->db == NULL || strcmp(db,thd->db) != 0)
{
- built_query.append(db);
- built_query.append("`.`");
+ append_identifier(thd, &built_query, db, db_len);
+ built_query.append(".");
}
- built_query.append(table->table_name);
- built_query.append("`,");
+ append_identifier(thd, &built_query, table->table_name,
+ strlen(table->table_name));
+ built_query.append(",");
}
}
DEBUG_SYNC(thd, "rm_table_no_locks_before_delete_table");
diff --git a/sql/sql_truncate.cc b/sql/sql_truncate.cc
index 67ed608f114..2285131fade 100644
--- a/sql/sql_truncate.cc
+++ b/sql/sql_truncate.cc
@@ -24,6 +24,7 @@
#include "sql_acl.h" // DROP_ACL
#include "sql_parse.h" // check_one_table_access()
#include "sql_truncate.h"
+#include "sql_show.h" //append_identifier()
/**
@@ -43,9 +44,8 @@ static bool fk_info_append_fields(String *str, List<LEX_STRING> *fields)
while ((field= it++))
{
- res|= str->append("`");
- res|= str->append(field);
- res|= str->append("`, ");
+ append_identifier(NULL, str, field->str, field->length);
+ res|= str->append(", ");
}
str->chop();
@@ -76,19 +76,23 @@ static const char *fk_info_str(THD *thd, FOREIGN_KEY_INFO *fk_info)
`db`.`tbl`, CONSTRAINT `id` FOREIGN KEY (`fk`) REFERENCES `db`.`tbl` (`fk`)
*/
- res|= str.append('`');
- res|= str.append(fk_info->foreign_db);
- res|= str.append("`.`");
- res|= str.append(fk_info->foreign_table);
- res|= str.append("`, CONSTRAINT `");
- res|= str.append(fk_info->foreign_id);
- res|= str.append("` FOREIGN KEY (");
+ append_identifier(NULL, &str, fk_info->foreign_db->str,
+ fk_info->foreign_db->length);
+ res|= str.append(".");
+ append_identifier(NULL, &str, fk_info->foreign_table->str,
+ fk_info->foreign_table->length);
+ res|= str.append(", CONSTRAINT ");
+ append_identifier(NULL, &str, fk_info->foreign_id->str,
+ fk_info->foreign_id->length);
+ res|= str.append(" FOREIGN KEY (");
res|= fk_info_append_fields(&str, &fk_info->foreign_fields);
- res|= str.append(") REFERENCES `");
- res|= str.append(fk_info->referenced_db);
- res|= str.append("`.`");
- res|= str.append(fk_info->referenced_table);
- res|= str.append("` (");
+ res|= str.append(") REFERENCES ");
+ append_identifier(NULL, &str, fk_info->referenced_db->str,
+ fk_info->referenced_db->length);
+ res|= str.append(".");
+ append_identifier(NULL, &str, fk_info->referenced_table->str,
+ fk_info->referenced_table->length);
+ res|= str.append(" (");
res|= fk_info_append_fields(&str, &fk_info->referenced_fields);
res|= str.append(')');