diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 18:00:34 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-05-04 18:00:34 +0000 |
commit | 3f619478f796eddbba6e39502fe941b285dd97b1 (patch) | |
tree | e2c7b5777f728320e5b5542b6213fd3591ba51e2 /mysql-test/main/partition_utf8-debug.test | |
parent | Initial commit. (diff) | |
download | mariadb-3f619478f796eddbba6e39502fe941b285dd97b1.tar.xz mariadb-3f619478f796eddbba6e39502fe941b285dd97b1.zip |
Adding upstream version 1:10.11.6.upstream/1%10.11.6upstream
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'mysql-test/main/partition_utf8-debug.test')
-rw-r--r-- | mysql-test/main/partition_utf8-debug.test | 71 |
1 files changed, 71 insertions, 0 deletions
diff --git a/mysql-test/main/partition_utf8-debug.test b/mysql-test/main/partition_utf8-debug.test new file mode 100644 index 00000000..c321c944 --- /dev/null +++ b/mysql-test/main/partition_utf8-debug.test @@ -0,0 +1,71 @@ +--source include/have_partition.inc +--source include/have_debug_sync.inc + +--echo # +--echo # Start of 10.5 tests +--echo # + +--echo # +--echo # MDEV-20856 Bad values in metadata views for partitions on VARBINARY +--echo # + +SET NAMES utf8; +SET @save_dbug = @@debug_dbug; +SET SESSION debug_dbug="+d,generate_partition_syntax_for_frm"; + + +--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED +CREATE OR REPLACE TABLE t1 (a VARCHAR(10)) CHARACTER SET latin1 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN (_utf8'Ṡ')); + +--error ER_PARTITION_FUNCTION_IS_NOT_ALLOWED +CREATE OR REPLACE TABLE t1 (a VARCHAR(10)) CHARACTER SET latin1 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN ('Ṡ')); + +CREATE OR REPLACE TABLE t1 (a VARCHAR(10)) CHARACTER SET latin1 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN (_latin1 0xDF)); +SELECT PARTITION_DESCRIPTION FROM INFORMATION_SCHEMA.PARTITIONS WHERE TABLE_NAME='t1'; +DROP TABLE t1; + +CREATE OR REPLACE TABLE t1 (a VARCHAR(10)) CHARACTER SET latin1 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN (_utf8'ß')); +SELECT PARTITION_DESCRIPTION FROM INFORMATION_SCHEMA.PARTITIONS WHERE TABLE_NAME='t1'; +DROP TABLE t1; + +CREATE OR REPLACE TABLE t1 (a VARCHAR(10)) CHARACTER SET latin1 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN ('ß')); +DROP TABLE t1; + +CREATE OR REPLACE TABLE t1 (a VARCHAR(10)) CHARACTER SET utf8 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN (_utf8'ß')); +SELECT PARTITION_DESCRIPTION FROM INFORMATION_SCHEMA.PARTITIONS WHERE TABLE_NAME='t1'; +DROP TABLE t1; + +CREATE OR REPLACE TABLE t1 (a VARCHAR(10)) CHARACTER SET utf8 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN ('ß')); +SELECT PARTITION_DESCRIPTION FROM INFORMATION_SCHEMA.PARTITIONS WHERE TABLE_NAME='t1'; +DROP TABLE t1; + + +CREATE OR REPLACE TABLE t1 (a VARBINARY(10)) CHARACTER SET utf8 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN (0xFF)); +SELECT PARTITION_DESCRIPTION FROM INFORMATION_SCHEMA.PARTITIONS WHERE TABLE_NAME='t1'; +DROP TABLE t1; + + +CREATE OR REPLACE TABLE t1 (a DATE) CHARACTER SET utf8 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN (FROM_DAYS(NULL))); +SELECT PARTITION_DESCRIPTION FROM INFORMATION_SCHEMA.PARTITIONS WHERE TABLE_NAME='t1'; +DROP TABLE t1; + +CREATE OR REPLACE TABLE t1 (a DATE) CHARACTER SET utf8 + PARTITION BY LIST COLUMNS (a) (PARTITION p0 VALUES IN (FROM_DAYS(100))); +SELECT PARTITION_DESCRIPTION FROM INFORMATION_SCHEMA.PARTITIONS WHERE TABLE_NAME='t1'; +DROP TABLE t1; + + +SET debug_dbug=@save_dbug; + +--echo # +--echo # End of 10.5 tests +--echo # |