Debian Codegraph @

mysql-test/suite/rpl/r/rpl_row_basic_8partition.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 SET @@BINLOG_FORMAT = ROW;
7 SELECT @@BINLOG_FORMAT;
8 @@BINLOG_FORMAT
9 ROW
10 Warnings:
11 Warning 1287 '@@binlog_format' is deprecated and will be removed in a future release.
12 **** Partition RANGE testing ****
13 CREATE TABLE t1 (id MEDIUMINT NOT NULL, b1 BIT(8), vc VARCHAR(255),
14 bc CHAR(255), d DECIMAL(10,4) DEFAULT 0,
15 f FLOAT DEFAULT 0, total BIGINT UNSIGNED,
16 y YEAR, t DATE)
17 PARTITION BY RANGE (YEAR(t))
18 (PARTITION p0 VALUES LESS THAN (1901),
19 PARTITION p1 VALUES LESS THAN (1946),
20 PARTITION p2 VALUES LESS THAN (1966),
21 PARTITION p3 VALUES LESS THAN (1986),
22 PARTITION p4 VALUES LESS THAN (2005),
23 PARTITION p5 VALUES LESS THAN MAXVALUE);
24 --- On master ---
25 SHOW CREATE TABLE t1;
26 Table Create Table
27 t1 CREATE TABLE `t1` (
28 `id` mediumint NOT NULL,
29 `b1` bit(8) DEFAULT NULL,
30 `vc` varchar(255) DEFAULT NULL,
31 `bc` char(255) DEFAULT NULL,
32 `d` decimal(10,4) DEFAULT '0.0000',
33 `f` float DEFAULT '0',
34 `total` bigint unsigned DEFAULT NULL,
35 `y` year DEFAULT NULL,
36 `t` date DEFAULT NULL
37 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
38 /*!50100 PARTITION BY RANGE (year(`t`))
39 (PARTITION p0 VALUES LESS THAN (1901) ENGINE = ENGINE,
40 PARTITION p1 VALUES LESS THAN (1946) ENGINE = ENGINE,
41 PARTITION p2 VALUES LESS THAN (1966) ENGINE = ENGINE,
42 PARTITION p3 VALUES LESS THAN (1986) ENGINE = ENGINE,
43 PARTITION p4 VALUES LESS THAN (2005) ENGINE = ENGINE,
44 PARTITION p5 VALUES LESS THAN MAXVALUE ENGINE = ENGINE) */
45 --- On slave --
46 include/sync_slave_sql_with_master.inc
47 SHOW CREATE TABLE t1;
48 Table Create Table
49 t1 CREATE TABLE `t1` (
50 `id` mediumint NOT NULL,
51 `b1` bit(8) DEFAULT NULL,
52 `vc` varchar(255) DEFAULT NULL,
53 `bc` char(255) DEFAULT NULL,
54 `d` decimal(10,4) DEFAULT '0.0000',
55 `f` float DEFAULT '0',
56 `total` bigint unsigned DEFAULT NULL,
57 `y` year DEFAULT NULL,
58 `t` date DEFAULT NULL
59 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
60 /*!50100 PARTITION BY RANGE (year(`t`))
61 (PARTITION p0 VALUES LESS THAN (1901) ENGINE = ENGINE,
62 PARTITION p1 VALUES LESS THAN (1946) ENGINE = ENGINE,
63 PARTITION p2 VALUES LESS THAN (1966) ENGINE = ENGINE,
64 PARTITION p3 VALUES LESS THAN (1986) ENGINE = ENGINE,
65 PARTITION p4 VALUES LESS THAN (2005) ENGINE = ENGINE,
66 PARTITION p5 VALUES LESS THAN MAXVALUE ENGINE = ENGINE) */
67 "--- Insert into t1 --" as "";
68 --- Select from t1 on master ---
69 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
70 id hex(b1) vc bc d f total y t
71 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
72 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
73 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
74 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
75 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
76 --- Select from t1 on slave ---
77 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
78 id hex(b1) vc bc d f total y t
79 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
80 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
81 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
82 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
83 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
84 --- Update t1 on master --
85 UPDATE t1 SET b1 = 0, t="2006-02-22" WHERE id = 412;
86 --- Check the update on master ---
87 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
88 id hex(b1) vc bc d f total y t
89 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
90 --- Check Update on slave ---
91 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
92 id hex(b1) vc bc d f total y t
93 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
94 --- Remove a record from t1 on master ---
95 DELETE FROM t1 WHERE id = 42;
96 --- Show current count on master for t1 ---
97 SELECT COUNT(*) FROM t1;
98 COUNT(*)
99 4
100 --- Show current count on slave for t1 ---
101 SELECT COUNT(*) FROM t1;
102 COUNT(*)
103 4
104 DELETE FROM t1;
105 ALTER TABLE t1 MODIFY vc TEXT;
106 --- On master ---
107 SHOW CREATE TABLE t1;
108 Table Create Table
109 t1 CREATE TABLE `t1` (
110 `id` mediumint NOT NULL,
111 `b1` bit(8) DEFAULT NULL,
112 `vc` text,
113 `bc` char(255) DEFAULT NULL,
114 `d` decimal(10,4) DEFAULT '0.0000',
115 `f` float DEFAULT '0',
116 `total` bigint unsigned DEFAULT NULL,
117 `y` year DEFAULT NULL,
118 `t` date DEFAULT NULL
119 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
120 /*!50100 PARTITION BY RANGE (year(`t`))
121 (PARTITION p0 VALUES LESS THAN (1901) ENGINE = ENGINE,
122 PARTITION p1 VALUES LESS THAN (1946) ENGINE = ENGINE,
123 PARTITION p2 VALUES LESS THAN (1966) ENGINE = ENGINE,
124 PARTITION p3 VALUES LESS THAN (1986) ENGINE = ENGINE,
125 PARTITION p4 VALUES LESS THAN (2005) ENGINE = ENGINE,
126 PARTITION p5 VALUES LESS THAN MAXVALUE ENGINE = ENGINE) */
127 --- On slave ---
128 include/sync_slave_sql_with_master.inc
129 SHOW CREATE TABLE t1;
130 Table Create Table
131 t1 CREATE TABLE `t1` (
132 `id` mediumint NOT NULL,
133 `b1` bit(8) DEFAULT NULL,
134 `vc` text,
135 `bc` char(255) DEFAULT NULL,
136 `d` decimal(10,4) DEFAULT '0.0000',
137 `f` float DEFAULT '0',
138 `total` bigint unsigned DEFAULT NULL,
139 `y` year DEFAULT NULL,
140 `t` date DEFAULT NULL
141 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
142 /*!50100 PARTITION BY RANGE (year(`t`))
143 (PARTITION p0 VALUES LESS THAN (1901) ENGINE = ENGINE,
144 PARTITION p1 VALUES LESS THAN (1946) ENGINE = ENGINE,
145 PARTITION p2 VALUES LESS THAN (1966) ENGINE = ENGINE,
146 PARTITION p3 VALUES LESS THAN (1986) ENGINE = ENGINE,
147 PARTITION p4 VALUES LESS THAN (2005) ENGINE = ENGINE,
148 PARTITION p5 VALUES LESS THAN MAXVALUE ENGINE = ENGINE) */
149 "--- Insert into t1 --" as "";
150 --- Select from t1 on master ---
151 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
152 id hex(b1) vc bc d f total y t
153 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
154 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
155 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
156 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
157 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
158 --- Select from t1 on slave ---
159 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
160 id hex(b1) vc bc d f total y t
161 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
162 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
163 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
164 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
165 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
166 --- Update t1 on master --
167 UPDATE t1 SET b1 = 0, t="2006-02-22" WHERE id = 412;
168 --- Check the update on master ---
169 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
170 id hex(b1) vc bc d f total y t
171 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
172 --- Check Update on slave ---
173 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
174 id hex(b1) vc bc d f total y t
175 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
176 --- Remove a record from t1 on master ---
177 DELETE FROM t1 WHERE id = 42;
178 --- Show current count on master for t1 ---
179 SELECT COUNT(*) FROM t1;
180 COUNT(*)
181 4
182 --- Show current count on slave for t1 ---
183 SELECT COUNT(*) FROM t1;
184 COUNT(*)
185 4
186 DELETE FROM t1;
187 DROP TABLE IF EXISTS t1;
188 **** Partition LIST testing ****
189 CREATE TABLE t1 (id MEDIUMINT NOT NULL, b1 BIT(8), vc VARCHAR(255),
190 bc CHAR(255), d DECIMAL(10,4) DEFAULT 0,
191 f FLOAT DEFAULT 0, total BIGINT UNSIGNED,
192 y YEAR, t DATE)
193 PARTITION BY LIST(id)
194 (PARTITION p0 VALUES IN (2, 4),
195 PARTITION p1 VALUES IN (42, 142),
196 PARTITION p2 VALUES IN (412));
197 --- On master ---
198 SHOW CREATE TABLE t1;
199 Table Create Table
200 t1 CREATE TABLE `t1` (
201 `id` mediumint NOT NULL,
202 `b1` bit(8) DEFAULT NULL,
203 `vc` varchar(255) DEFAULT NULL,
204 `bc` char(255) DEFAULT NULL,
205 `d` decimal(10,4) DEFAULT '0.0000',
206 `f` float DEFAULT '0',
207 `total` bigint unsigned DEFAULT NULL,
208 `y` year DEFAULT NULL,
209 `t` date DEFAULT NULL
210 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
211 /*!50100 PARTITION BY LIST (`id`)
212 (PARTITION p0 VALUES IN (2,4) ENGINE = ENGINE,
213 PARTITION p1 VALUES IN (42,142) ENGINE = ENGINE,
214 PARTITION p2 VALUES IN (412) ENGINE = ENGINE) */
215 --- On slave ---
216 include/sync_slave_sql_with_master.inc
217 SHOW CREATE TABLE t1;
218 Table Create Table
219 t1 CREATE TABLE `t1` (
220 `id` mediumint NOT NULL,
221 `b1` bit(8) DEFAULT NULL,
222 `vc` varchar(255) DEFAULT NULL,
223 `bc` char(255) DEFAULT NULL,
224 `d` decimal(10,4) DEFAULT '0.0000',
225 `f` float DEFAULT '0',
226 `total` bigint unsigned DEFAULT NULL,
227 `y` year DEFAULT NULL,
228 `t` date DEFAULT NULL
229 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
230 /*!50100 PARTITION BY LIST (`id`)
231 (PARTITION p0 VALUES IN (2,4) ENGINE = ENGINE,
232 PARTITION p1 VALUES IN (42,142) ENGINE = ENGINE,
233 PARTITION p2 VALUES IN (412) ENGINE = ENGINE) */
234 "--- Insert into t1 --" as "";
235 --- Select from t1 on master ---
236 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
237 id hex(b1) vc bc d f total y t
238 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
239 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
240 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
241 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
242 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
243 --- Select from t1 on slave ---
244 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
245 id hex(b1) vc bc d f total y t
246 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
247 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
248 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
249 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
250 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
251 --- Update t1 on master --
252 UPDATE t1 SET b1 = 0, t="2006-02-22" WHERE id = 412;
253 --- Check the update on master ---
254 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
255 id hex(b1) vc bc d f total y t
256 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
257 --- Check Update on slave ---
258 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
259 id hex(b1) vc bc d f total y t
260 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
261 --- Remove a record from t1 on master ---
262 DELETE FROM t1 WHERE id = 42;
263 --- Show current count on master for t1 ---
264 SELECT COUNT(*) FROM t1;
265 COUNT(*)
266 4
267 --- Show current count on slave for t1 ---
268 SELECT COUNT(*) FROM t1;
269 COUNT(*)
270 4
271 DELETE FROM t1;
272 ALTER TABLE t1 MODIFY vc TEXT;
273 --- On master ---
274 SHOW CREATE TABLE t1;
275 Table Create Table
276 t1 CREATE TABLE `t1` (
277 `id` mediumint NOT NULL,
278 `b1` bit(8) DEFAULT NULL,
279 `vc` text,
280 `bc` char(255) DEFAULT NULL,
281 `d` decimal(10,4) DEFAULT '0.0000',
282 `f` float DEFAULT '0',
283 `total` bigint unsigned DEFAULT NULL,
284 `y` year DEFAULT NULL,
285 `t` date DEFAULT NULL
286 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
287 /*!50100 PARTITION BY LIST (`id`)
288 (PARTITION p0 VALUES IN (2,4) ENGINE = ENGINE,
289 PARTITION p1 VALUES IN (42,142) ENGINE = ENGINE,
290 PARTITION p2 VALUES IN (412) ENGINE = ENGINE) */
291 --- On slave ---
292 include/sync_slave_sql_with_master.inc
293 SHOW CREATE TABLE t1;
294 Table Create Table
295 t1 CREATE TABLE `t1` (
296 `id` mediumint NOT NULL,
297 `b1` bit(8) DEFAULT NULL,
298 `vc` text,
299 `bc` char(255) DEFAULT NULL,
300 `d` decimal(10,4) DEFAULT '0.0000',
301 `f` float DEFAULT '0',
302 `total` bigint unsigned DEFAULT NULL,
303 `y` year DEFAULT NULL,
304 `t` date DEFAULT NULL
305 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
306 /*!50100 PARTITION BY LIST (`id`)
307 (PARTITION p0 VALUES IN (2,4) ENGINE = ENGINE,
308 PARTITION p1 VALUES IN (42,142) ENGINE = ENGINE,
309 PARTITION p2 VALUES IN (412) ENGINE = ENGINE) */
310 "--- Insert into t1 --" as "";
311 --- Select from t1 on master ---
312 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
313 id hex(b1) vc bc d f total y t
314 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
315 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
316 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
317 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
318 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
319 --- Select from t1 on slave ---
320 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
321 id hex(b1) vc bc d f total y t
322 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
323 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
324 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
325 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
326 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
327 --- Update t1 on master --
328 UPDATE t1 SET b1 = 0, t="2006-02-22" WHERE id = 412;
329 --- Check the update on master ---
330 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
331 id hex(b1) vc bc d f total y t
332 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
333 --- Check Update on slave ---
334 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
335 id hex(b1) vc bc d f total y t
336 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
337 --- Remove a record from t1 on master ---
338 DELETE FROM t1 WHERE id = 42;
339 --- Show current count on master for t1 ---
340 SELECT COUNT(*) FROM t1;
341 COUNT(*)
342 4
343 --- Show current count on slave for t1 ---
344 SELECT COUNT(*) FROM t1;
345 COUNT(*)
346 4
347 DELETE FROM t1;
348 DROP TABLE IF EXISTS t1;
349 **** Partition HASH testing ****
350 CREATE TABLE t1 (id MEDIUMINT NOT NULL, b1 BIT(8), vc VARCHAR(255),
351 bc CHAR(255), d DECIMAL(10,4) DEFAULT 0,
352 f FLOAT DEFAULT 0, total BIGINT UNSIGNED,
353 y YEAR, t DATE)
354 PARTITION BY HASH( YEAR(t) )
355 PARTITIONS 4;
356 --- On master ---
357 SHOW CREATE TABLE t1;
358 Table Create Table
359 t1 CREATE TABLE `t1` (
360 `id` mediumint NOT NULL,
361 `b1` bit(8) DEFAULT NULL,
362 `vc` varchar(255) DEFAULT NULL,
363 `bc` char(255) DEFAULT NULL,
364 `d` decimal(10,4) DEFAULT '0.0000',
365 `f` float DEFAULT '0',
366 `total` bigint unsigned DEFAULT NULL,
367 `y` year DEFAULT NULL,
368 `t` date DEFAULT NULL
369 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
370 /*!50100 PARTITION BY HASH (year(`t`))
371 PARTITIONS 4 */
372 --- On slave ---
373 include/sync_slave_sql_with_master.inc
374 SHOW CREATE TABLE t1;
375 Table Create Table
376 t1 CREATE TABLE `t1` (
377 `id` mediumint NOT NULL,
378 `b1` bit(8) DEFAULT NULL,
379 `vc` varchar(255) DEFAULT NULL,
380 `bc` char(255) DEFAULT NULL,
381 `d` decimal(10,4) DEFAULT '0.0000',
382 `f` float DEFAULT '0',
383 `total` bigint unsigned DEFAULT NULL,
384 `y` year DEFAULT NULL,
385 `t` date DEFAULT NULL
386 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
387 /*!50100 PARTITION BY HASH (year(`t`))
388 PARTITIONS 4 */
389 "--- Insert into t1 --" as "";
390 --- Select from t1 on master ---
391 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
392 id hex(b1) vc bc d f total y t
393 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
394 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
395 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
396 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
397 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
398 --- Select from t1 on slave ---
399 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
400 id hex(b1) vc bc d f total y t
401 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
402 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
403 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
404 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
405 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
406 --- Update t1 on master --
407 UPDATE t1 SET b1 = 0, t="2006-02-22" WHERE id = 412;
408 --- Check the update on master ---
409 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
410 id hex(b1) vc bc d f total y t
411 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
412 --- Check Update on slave ---
413 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
414 id hex(b1) vc bc d f total y t
415 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
416 --- Remove a record from t1 on master ---
417 DELETE FROM t1 WHERE id = 42;
418 --- Show current count on master for t1 ---
419 SELECT COUNT(*) FROM t1;
420 COUNT(*)
421 4
422 --- Show current count on slave for t1 ---
423 SELECT COUNT(*) FROM t1;
424 COUNT(*)
425 4
426 DELETE FROM t1;
427 ALTER TABLE t1 MODIFY vc TEXT;
428 --- On master ---
429 SHOW CREATE TABLE t1;
430 Table Create Table
431 t1 CREATE TABLE `t1` (
432 `id` mediumint NOT NULL,
433 `b1` bit(8) DEFAULT NULL,
434 `vc` text,
435 `bc` char(255) DEFAULT NULL,
436 `d` decimal(10,4) DEFAULT '0.0000',
437 `f` float DEFAULT '0',
438 `total` bigint unsigned DEFAULT NULL,
439 `y` year DEFAULT NULL,
440 `t` date DEFAULT NULL
441 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
442 /*!50100 PARTITION BY HASH (year(`t`))
443 PARTITIONS 4 */
444 --- On slave ---
445 include/sync_slave_sql_with_master.inc
446 SHOW CREATE TABLE t1;
447 Table Create Table
448 t1 CREATE TABLE `t1` (
449 `id` mediumint NOT NULL,
450 `b1` bit(8) DEFAULT NULL,
451 `vc` text,
452 `bc` char(255) DEFAULT NULL,
453 `d` decimal(10,4) DEFAULT '0.0000',
454 `f` float DEFAULT '0',
455 `total` bigint unsigned DEFAULT NULL,
456 `y` year DEFAULT NULL,
457 `t` date DEFAULT NULL
458 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
459 /*!50100 PARTITION BY HASH (year(`t`))
460 PARTITIONS 4 */
461 "--- Insert into t1 --" as "";
462 --- Select from t1 on master ---
463 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
464 id hex(b1) vc bc d f total y t
465 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
466 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
467 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
468 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
469 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
470 --- Select from t1 on slave ---
471 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
472 id hex(b1) vc bc d f total y t
473 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
474 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
475 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
476 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
477 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
478 --- Update t1 on master --
479 UPDATE t1 SET b1 = 0, t="2006-02-22" WHERE id = 412;
480 --- Check the update on master ---
481 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
482 id hex(b1) vc bc d f total y t
483 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
484 --- Check Update on slave ---
485 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
486 id hex(b1) vc bc d f total y t
487 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
488 --- Remove a record from t1 on master ---
489 DELETE FROM t1 WHERE id = 42;
490 --- Show current count on master for t1 ---
491 SELECT COUNT(*) FROM t1;
492 COUNT(*)
493 4
494 --- Show current count on slave for t1 ---
495 SELECT COUNT(*) FROM t1;
496 COUNT(*)
497 4
498 DELETE FROM t1;
499 DROP TABLE IF EXISTS t1;
500 **** Partition by KEY ****
501 CREATE TABLE t1 (id MEDIUMINT NOT NULL, b1 BIT(8), vc VARCHAR(255),
502 bc CHAR(255), d DECIMAL(10,4) DEFAULT 0,
503 f FLOAT DEFAULT 0, total BIGINT UNSIGNED,
504 y YEAR, t DATE,PRIMARY KEY(id))
505 PARTITION BY KEY()
506 PARTITIONS 4;
507 --- On master ---
508 SHOW CREATE TABLE t1;
509 Table Create Table
510 t1 CREATE TABLE `t1` (
511 `id` mediumint NOT NULL,
512 `b1` bit(8) DEFAULT NULL,
513 `vc` varchar(255) DEFAULT NULL,
514 `bc` char(255) DEFAULT NULL,
515 `d` decimal(10,4) DEFAULT '0.0000',
516 `f` float DEFAULT '0',
517 `total` bigint unsigned DEFAULT NULL,
518 `y` year DEFAULT NULL,
519 `t` date DEFAULT NULL,
520 PRIMARY KEY (`id`)
521 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
522 /*!50100 PARTITION BY KEY ()
523 PARTITIONS 4 */
524 --- On slave ---
525 include/sync_slave_sql_with_master.inc
526 SHOW CREATE TABLE t1;
527 Table Create Table
528 t1 CREATE TABLE `t1` (
529 `id` mediumint NOT NULL,
530 `b1` bit(8) DEFAULT NULL,
531 `vc` varchar(255) DEFAULT NULL,
532 `bc` char(255) DEFAULT NULL,
533 `d` decimal(10,4) DEFAULT '0.0000',
534 `f` float DEFAULT '0',
535 `total` bigint unsigned DEFAULT NULL,
536 `y` year DEFAULT NULL,
537 `t` date DEFAULT NULL,
538 PRIMARY KEY (`id`)
539 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
540 /*!50100 PARTITION BY KEY ()
541 PARTITIONS 4 */
542 "--- Insert into t1 --" as "";
543 --- Select from t1 on master ---
544 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
545 id hex(b1) vc bc d f total y t
546 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
547 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
548 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
549 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
550 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
551 --- Select from t1 on slave ---
552 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
553 id hex(b1) vc bc d f total y t
554 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
555 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
556 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
557 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
558 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
559 --- Update t1 on master --
560 UPDATE t1 SET b1 = 0, t="2006-02-22" WHERE id = 412;
561 --- Check the update on master ---
562 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
563 id hex(b1) vc bc d f total y t
564 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
565 --- Check Update on slave ---
566 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
567 id hex(b1) vc bc d f total y t
568 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
569 --- Remove a record from t1 on master ---
570 DELETE FROM t1 WHERE id = 42;
571 --- Show current count on master for t1 ---
572 SELECT COUNT(*) FROM t1;
573 COUNT(*)
574 4
575 --- Show current count on slave for t1 ---
576 SELECT COUNT(*) FROM t1;
577 COUNT(*)
578 4
579 DELETE FROM t1;
580 ALTER TABLE t1 DROP PRIMARY KEY, ADD PRIMARY KEY(id, total);
581 --- On master ---
582 SHOW CREATE TABLE t1;
583 Table Create Table
584 t1 CREATE TABLE `t1` (
585 `id` mediumint NOT NULL,
586 `b1` bit(8) DEFAULT NULL,
587 `vc` varchar(255) DEFAULT NULL,
588 `bc` char(255) DEFAULT NULL,
589 `d` decimal(10,4) DEFAULT '0.0000',
590 `f` float DEFAULT '0',
591 `total` bigint unsigned NOT NULL,
592 `y` year DEFAULT NULL,
593 `t` date DEFAULT NULL,
594 PRIMARY KEY (`id`,`total`)
595 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
596 /*!50100 PARTITION BY KEY ()
597 PARTITIONS 4 */
598 --- On slave ---
599 include/sync_slave_sql_with_master.inc
600 SHOW CREATE TABLE t1;
601 Table Create Table
602 t1 CREATE TABLE `t1` (
603 `id` mediumint NOT NULL,
604 `b1` bit(8) DEFAULT NULL,
605 `vc` varchar(255) DEFAULT NULL,
606 `bc` char(255) DEFAULT NULL,
607 `d` decimal(10,4) DEFAULT '0.0000',
608 `f` float DEFAULT '0',
609 `total` bigint unsigned NOT NULL,
610 `y` year DEFAULT NULL,
611 `t` date DEFAULT NULL,
612 PRIMARY KEY (`id`,`total`)
613 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
614 /*!50100 PARTITION BY KEY ()
615 PARTITIONS 4 */
616 "--- Insert into t1 --" as "";
617 --- Select from t1 on master ---
618 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
619 id hex(b1) vc bc d f total y t
620 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
621 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
622 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
623 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
624 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
625 --- Select from t1 on slave ---
626 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
627 id hex(b1) vc bc d f total y t
628 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
629 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
630 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
631 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
632 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
633 --- Update t1 on master --
634 UPDATE t1 SET b1 = 0, t="2006-02-22" WHERE id = 412;
635 --- Check the update on master ---
636 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
637 id hex(b1) vc bc d f total y t
638 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
639 --- Check Update on slave ---
640 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
641 id hex(b1) vc bc d f total y t
642 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
643 --- Remove a record from t1 on master ---
644 DELETE FROM t1 WHERE id = 42;
645 --- Show current count on master for t1 ---
646 SELECT COUNT(*) FROM t1;
647 COUNT(*)
648 4
649 --- Show current count on slave for t1 ---
650 SELECT COUNT(*) FROM t1;
651 COUNT(*)
652 4
653 DELETE FROM t1;
654 ALTER TABLE t1 MODIFY vc TEXT;
655 --- On master ---
656 SHOW CREATE TABLE t1;
657 Table Create Table
658 t1 CREATE TABLE `t1` (
659 `id` mediumint NOT NULL,
660 `b1` bit(8) DEFAULT NULL,
661 `vc` text,
662 `bc` char(255) DEFAULT NULL,
663 `d` decimal(10,4) DEFAULT '0.0000',
664 `f` float DEFAULT '0',
665 `total` bigint unsigned NOT NULL,
666 `y` year DEFAULT NULL,
667 `t` date DEFAULT NULL,
668 PRIMARY KEY (`id`,`total`)
669 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
670 /*!50100 PARTITION BY KEY ()
671 PARTITIONS 4 */
672 --- On slave ---
673 include/sync_slave_sql_with_master.inc
674 SHOW CREATE TABLE t1;
675 Table Create Table
676 t1 CREATE TABLE `t1` (
677 `id` mediumint NOT NULL,
678 `b1` bit(8) DEFAULT NULL,
679 `vc` text,
680 `bc` char(255) DEFAULT NULL,
681 `d` decimal(10,4) DEFAULT '0.0000',
682 `f` float DEFAULT '0',
683 `total` bigint unsigned NOT NULL,
684 `y` year DEFAULT NULL,
685 `t` date DEFAULT NULL,
686 PRIMARY KEY (`id`,`total`)
687 ) ENGINE=ENGINE DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_0900_ai_ci
688 /*!50100 PARTITION BY KEY ()
689 PARTITIONS 4 */
690 "--- Insert into t1 --" as "";
691 --- Select from t1 on master ---
692 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
693 id hex(b1) vc bc d f total y t
694 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
695 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
696 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
697 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
698 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
699 --- Select from t1 on slave ---
700 select id,hex(b1),vc,bc,d,f,total,y,t from t1 order by id;
701 id hex(b1) vc bc d f total y t
702 2 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1965-11-14
703 4 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1985-11-14
704 42 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1905-11-14
705 142 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 1995-11-14
706 412 1 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2005-11-14
707 --- Update t1 on master --
708 UPDATE t1 SET b1 = 0, t="2006-02-22" WHERE id = 412;
709 --- Check the update on master ---
710 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
711 id hex(b1) vc bc d f total y t
712 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
713 --- Check Update on slave ---
714 SELECT id,hex(b1),vc,bc,d,f,total,y,t FROM t1 WHERE id = 412;
715 id hex(b1) vc bc d f total y t
716 412 0 Testing MySQL databases is a cool Must make it bug free for the customer 654321.4321 15.21 0 1965 2006-02-22
717 --- Remove a record from t1 on master ---
718 DELETE FROM t1 WHERE id = 42;
719 --- Show current count on master for t1 ---
720 SELECT COUNT(*) FROM t1;
721 COUNT(*)
722 4
723 --- Show current count on slave for t1 ---
724 SELECT COUNT(*) FROM t1;
725 COUNT(*)
726 4
727 DELETE FROM t1;
728 DROP TABLE IF EXISTS t1;
729 include/rpl_end.inc