summaryrefslogtreecommitdiff
path: root/mysql-test/r/partition_column.result
diff options
context:
space:
mode:
authorMikael Ronstrom <mikael@mysql.com>2009-10-01 16:50:11 +0200
committerMikael Ronstrom <mikael@mysql.com>2009-10-01 16:50:11 +0200
commit4d624635c58520e933f54e1e25b68c9c42e19816 (patch)
treee7a83b5125be7617003807d6266bc015b4495d75 /mysql-test/r/partition_column.result
parent66ea81cdb1f6499d8661d6f0c0750218bcb326c5 (diff)
downloadmariadb-git-4d624635c58520e933f54e1e25b68c9c42e19816.tar.gz
Added more test cases
Diffstat (limited to 'mysql-test/r/partition_column.result')
-rw-r--r--mysql-test/r/partition_column.result40
1 files changed, 40 insertions, 0 deletions
diff --git a/mysql-test/r/partition_column.result b/mysql-test/r/partition_column.result
index 0aaa4e78f68..66308321a95 100644
--- a/mysql-test/r/partition_column.result
+++ b/mysql-test/r/partition_column.result
@@ -1,4 +1,36 @@
drop table if exists t1;
+create table t1 (a int, b int)
+partition by list column_list(a,b)
+( partition p0 values in (column_list(1, NULL), column_list(2, NULL),
+column_list(NULL, NULL)),
+partition p1 values in (column_list(1,1), column_list(2,2)),
+partition p2 values in (column_list(3, NULL), column_list(NULL, 1)));
+insert into t1 values (3, NULL);
+insert into t1 values (NULL, 1);
+insert into t1 values (NULL, NULL);
+insert into t1 values (1, NULL);
+insert into t1 values (2, NULL);
+insert into t1 values (1,1);
+insert into t1 values (2,2);
+select * from t1 where a = 1;
+a b
+1 NULL
+1 1
+select * from t1 where a = 2;
+a b
+2 NULL
+2 2
+show create table t1;
+Table Create Table
+t1 CREATE TABLE `t1` (
+ `a` int(11) DEFAULT NULL,
+ `b` int(11) DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
+/*!50100 PARTITION BY LIST COLUMN_LIST(a,b)
+(PARTITION p0 VALUES IN ( COLUMN_LIST(1,NULL), COLUMN_LIST(2,NULL), COLUMN_LIST(NULL,NULL)) ENGINE = MyISAM,
+ PARTITION p1 VALUES IN ( COLUMN_LIST(1,1), COLUMN_LIST(2,2)) ENGINE = MyISAM,
+ PARTITION p2 VALUES IN ( COLUMN_LIST(3,NULL), COLUMN_LIST(NULL,1)) ENGINE = MyISAM) */
+drop table t1;
create table t1 (a int)
partition by list (a)
( partition p0 values in (1),
@@ -27,6 +59,14 @@ insert into t1 values (4);
insert into t1 values (NULL);
insert into t1 values (5);
ERROR HY000: Table has no partition for value from column_list
+show create table t1;
+Table Create Table
+t1 CREATE TABLE `t1` (
+ `a` int(11) DEFAULT NULL
+) ENGINE=MyISAM DEFAULT CHARSET=latin1
+/*!50100 PARTITION BY LIST COLUMN_LIST(a)
+(PARTITION p0 VALUES IN ( COLUMN_LIST(2), COLUMN_LIST(1)) ENGINE = MyISAM,
+ PARTITION p1 VALUES IN ( COLUMN_LIST(4), COLUMN_LIST(NULL), COLUMN_LIST(3)) ENGINE = MyISAM) */
drop table t1;
create table t1 (a int, b char(10), c varchar(25), d datetime)
partition by range column_list(a,b,c,d)