summaryrefslogtreecommitdiff
path: root/mysql-test
diff options
context:
space:
mode:
authorunknown <msvensson@neptunus.(none)>2006-04-07 11:46:22 +0200
committerunknown <msvensson@neptunus.(none)>2006-04-07 11:46:22 +0200
commit94bfe767b2c5c38415d4c14504b705d8d0a2a4ab (patch)
tree0d5a2245162f66ed3f9732bd3ce6a73ddaed4bb7 /mysql-test
parentf3de57d982df777be94d4952a0545854e75f1509 (diff)
parentc521a51340e7251dd0fe959fe3b9c3230047e7ab (diff)
downloadmariadb-git-94bfe767b2c5c38415d4c14504b705d8d0a2a4ab.tar.gz
Merge neptunus.(none):/home/msvensson/mysql/bug13228/my50-bug13228_minimal
into neptunus.(none):/home/msvensson/mysql/mysql-5.0 sql/ha_ndbcluster.cc: Auto merged
Diffstat (limited to 'mysql-test')
-rw-r--r--mysql-test/r/ndb_alter_table2.result42
-rw-r--r--mysql-test/t/ndb_alter_table2.test83
2 files changed, 125 insertions, 0 deletions
diff --git a/mysql-test/r/ndb_alter_table2.result b/mysql-test/r/ndb_alter_table2.result
new file mode 100644
index 00000000000..399578dc97b
--- /dev/null
+++ b/mysql-test/r/ndb_alter_table2.result
@@ -0,0 +1,42 @@
+DROP TABLE IF EXISTS t1;
+CREATE TABLE t1 (
+a INT NOT NULL PRIMARY KEY,
+b INT NOT NULL
+) ENGINE=ndbcluster;
+BEGIN;
+INSERT INTO t1 VALUES (9410,9412);
+BEGIN;
+INSERT INTO t1 VALUES (9411,9412);
+BEGIN;
+INSERT INTO t1 VALUES (9412,9412);
+BEGIN;
+INSERT INTO t1 VALUES (9413,9412);
+BEGIN;
+INSERT INTO t1 VALUES (9414,9412);
+BEGIN;
+INSERT INTO t1 VALUES (9415,9412);
+ROLLBACK;
+ROLLBACK;
+ROLLBACK;
+ROLLBACK;
+ROLLBACK;
+ROLLBACK;
+drop table t1;
+CREATE TABLE t1 (
+a INT NOT NULL PRIMARY KEY,
+b INT NOT NULL,
+c INT NOT NULL
+) ENGINE=ndbcluster;
+select * from t1;
+ERROR HY000: Got error 241 'Invalid schema object version' from ndbcluster
+select * from t1;
+a b c
+select * from t1;
+a b c
+select * from t1;
+a b c
+select * from t1;
+a b c
+select * from t1;
+a b c
+drop table t1;
diff --git a/mysql-test/t/ndb_alter_table2.test b/mysql-test/t/ndb_alter_table2.test
new file mode 100644
index 00000000000..3861fcc6c9d
--- /dev/null
+++ b/mysql-test/t/ndb_alter_table2.test
@@ -0,0 +1,83 @@
+-- source include/have_ndb.inc
+-- source include/have_multi_ndb.inc
+-- source include/not_embedded.inc
+
+--disable_warnings
+DROP TABLE IF EXISTS t1;
+--enable_warnings
+
+connect (con1,localhost,root,,test);
+connect (con2,localhost,root,,test);
+connect (con3,localhost,root,,test);
+connect (con4,localhost,root,,test);
+connect (con5,localhost,root,,test);
+connect (con6,localhost,root,,test);
+
+CREATE TABLE t1 (
+ a INT NOT NULL PRIMARY KEY,
+ b INT NOT NULL
+) ENGINE=ndbcluster;
+
+connection con1;
+BEGIN;
+INSERT INTO t1 VALUES (9410,9412);
+connection con2;
+BEGIN;
+--send
+INSERT INTO t1 VALUES (9411,9412);
+connection con3;
+BEGIN;
+--send
+INSERT INTO t1 VALUES (9412,9412);
+connection con4;
+BEGIN;
+--send
+INSERT INTO t1 VALUES (9413,9412);
+connection con5;
+BEGIN;
+--send
+INSERT INTO t1 VALUES (9414,9412);
+connection con6;
+BEGIN;
+--send
+INSERT INTO t1 VALUES (9415,9412);
+connection con1;
+sleep 1;
+
+ROLLBACK;
+connection con2;
+reap;
+ROLLBACK;
+connection con3;
+reap;
+ROLLBACK;
+connection con4;
+reap;
+ROLLBACK;
+connection con5;
+reap;
+ROLLBACK;
+connection con6;
+reap;
+ROLLBACK;
+
+connection server2;
+
+drop table t1;
+CREATE TABLE t1 (
+ a INT NOT NULL PRIMARY KEY,
+ b INT NOT NULL,
+ c INT NOT NULL
+) ENGINE=ndbcluster;
+
+connection server1;
+
+--error 1296
+select * from t1;
+select * from t1;
+select * from t1;
+select * from t1;
+select * from t1;
+select * from t1;
+
+drop table t1;