Debian Codegraph @

mysql-test/suite/rpl/r/rpl_check_sql_mode_differences.result

raw
1 include/master-slave.inc
2 Warnings:
3 Note #### Sending passwords in plain text without SSL/TLS is extremely insecure.
4 Note #### Storing MySQL user name or password information in the connection metadata repository is not secure and is therefore not recommended. Please consider using the USER and PASSWORD connection options for START REPLICA; see the 'START REPLICA Syntax' in the MySQL Manual for more information.
5 [connection master]
6
7 ##############################################################
8 # 1. Create a table where a generated column has the type TIME
9 [connection master]
10 CREATE TABLE t1 (
11 first DOUBLE,
12 gen_col TIME(1) GENERATED ALWAYS AS (`first`) VIRTUAL,
13 KEY (gen_col)
14 ) ENGINE=InnoDB;
15
16 ##############################################################
17 # 2. Change the source SQL mode to 'TIME_TRUNCATE_FRACTIONAL'
18 SET sql_mode='TIME_TRUNCATE_FRACTIONAL';
19
20 ##############################################################
21 # 3. Insert data on the source being the value of the generated column dependent on the SQL mode
22 INSERT INTO t1 (first) VALUES(1.55);
23
24 ##############################################################
25 # 4. Delete the row on the source and verify it was deleted on the replica
26 DELETE FROM t1 WHERE gen_col="00:00:01.5";
27 include/sync_slave_sql_with_master.inc
28 [connection slave]
29 include/assert.inc [The data on the replica was deleted]
30
31 ##############################################################
32 # 5. Cleanup
33 [connection master]
34 DROP TABLE t1;
35 include/rpl_end.inc