2017-11-06 18:58:04 +00:00
|
|
|
CREATE TABLE t(i int)
|
|
|
|
ENGINE=InnoDB
|
|
|
|
PARTITION BY RANGE (i)
|
|
|
|
(PARTITION p0 VALUES LESS THAN (100),
|
|
|
|
PARTITION P1 VALUES LESS THAN (200),
|
2017-11-06 21:00:06 +00:00
|
|
|
PARTITION p2 VALUES LESS THAN (300) DATA DIRECTORY = 'MYSQLTEST_VARDIR/partitdata',
|
|
|
|
PARTITION p3 VALUES LESS THAN (400) DATA DIRECTORY = 'MYSQLTEST_VARDIR/partitdata',
|
2017-11-06 18:58:04 +00:00
|
|
|
PARTITION p4 VALUES LESS THAN MAXVALUE);
|
|
|
|
INSERT INTO t VALUES (1), (101), (201), (301), (401);
|
|
|
|
DROP TABLE t;
|
|
|
|
# shutdown server
|
|
|
|
# remove datadir
|
|
|
|
# xtrabackup move back
|
|
|
|
# restart server
|
|
|
|
SELECT * FROM t;
|
|
|
|
i
|
|
|
|
1
|
|
|
|
101
|
|
|
|
201
|
|
|
|
301
|
|
|
|
401
|
|
|
|
DROP TABLE t;
|