diff options
author | unknown <pgalbraith/patg@buffy.netfrastructure.com> | 2006-07-25 18:38:09 -0400 |
---|---|---|
committer | unknown <pgalbraith/patg@buffy.netfrastructure.com> | 2006-07-25 18:38:09 -0400 |
commit | fe4d656d552c864affbffda7d330a120bcac87a5 (patch) | |
tree | b98e112465eeeea09ba51b1da858886fcef58cb0 /mysql-test/t/federated.test | |
parent | 9378fc627ecaf22d47bfd0de1c192953c96d5159 (diff) | |
download | mariadb-git-fe4d656d552c864affbffda7d330a120bcac87a5.tar.gz |
BUG #15133 "unique index with nullable value not accepted in federated table"
Added HA_NULL_IN_KEY to table flags to allow for nullable unique indexes
and added test to verify
ha_federated.h:
BUG #15133 "unique index with nullable value not accepted in federated table"
added HA_NULL_IN_KEY to table flags to allow for nullable unique indexes
federated.test:
BUG #15133 "unique index with nullable value not accepted in federated table"
New test to show that nullable unique indexes work
federated.result:
BUG #15133 "unique index with nullable value not accepted in federated table"
New results for new test
sql/ha_federated.h:
BUG #15133 "unique index with nullable value not accepted in federated table"
added HA_NULL_IN_KEY to table flags to allow for nullable unique indexes
mysql-test/t/federated.test:
BUG #15133 "unique index with nullable value not accepted in federated table"
New test to show that nullable unique indexes work
mysql-test/r/federated.result:
BUG #15133 "unique index with nullable value not accepted in federated table"
New results for new test
Diffstat (limited to 'mysql-test/t/federated.test')
-rw-r--r-- | mysql-test/t/federated.test | 45 |
1 files changed, 45 insertions, 0 deletions
diff --git a/mysql-test/t/federated.test b/mysql-test/t/federated.test index 38beab605fd..c2218b3451b 100644 --- a/mysql-test/t/federated.test +++ b/mysql-test/t/federated.test @@ -1499,4 +1499,49 @@ drop table t1; connection master; drop table t1; +# +# BUG #15133: unique index with nullable value not accepted in federated table +# + +connection slave; +--disable_warnings +DROP TABLE IF EXISTS federated.test; +CREATE TABLE federated.test ( + `i` int(11) NOT NULL, + `j` int(11) NOT NULL, + `c` varchar(30) default NULL, + PRIMARY KEY (`i`,`j`), + UNIQUE KEY `i` (`i`,`c`) +) ENGINE=InnoDB DEFAULT CHARSET=latin1; +--enable_warnings + +connection master; +--disable_warnings +DROP TABLE IF EXISTS federated.test1; +DROP TABLE IF EXISTS federated.test2; +--enable_warnings + +--replace_result $SLAVE_MYPORT SLAVE_PORT +eval create table federated.test1 ( + i int not null, + j int not null, + c varchar(30), + primary key (i,j), + unique key (i, c)) +engine = federated +connection='mysql://root@127.0.0.1:$SLAVE_MYPORT/federated/test'; + +--replace_result $SLAVE_MYPORT SLAVE_PORT +eval create table federated.test2 ( + i int default null, + j int not null, + c varchar(30), + key (i)) +engine = federated +connection='mysql://root@127.0.0.1:$SLAVE_MYPORT/federated/test'; +drop table federated.test1, federated.test2; + +connection slave; +drop table federated.test; + source include/federated_cleanup.inc; |