Debian Codegraph @

mysql-test/suite/ndbcluster/basic.test

raw
1 --source include/have_ndb.inc
2
3 #
4 # The very basic test
5 # - showing table can be created in the storage engine NDB
6 # - read and write the table
7 #
8 CREATE TABLE t1 (
9 a int PRIMARY KEY,
10 b varchar(255)
11 ) ENGINE = NDB;
12
13 INSERT INTO t1 VALUES (1, "MySQL Server with NDB");
14 INSERT INTO t1 (a, b) VALUES (11, "Barrier effect");
15 INSERT INTO t1 (a, b) VALUES
16 (12, "The third row"),
17 (37, "And of course number 37");
18 SELECT * FROM t1 WHERE a = 1;
19 UPDATE t1 SET b = CONCAT(b, " test") WHERE a = 1;
20 SELECT * FROM t1 WHERE a = 1;
21 REPLACE t1 (a, b) VALUES (12, "Another layer");
22 SELECT * FROM t1 WHERE a = 12 ORDER BY a;
23 DELETE FROM t1 WHERE a = 11;
24 SELECT COUNT(*) FROM t1;
25 SELECT b FROM t1 WHERE b LIKE "MySQL%";
26 DELETE FROM t1 ORDER BY b DESC;
27 DROP TABLE t1;
28
29 #
30 # NOTE! Don't add any more tests here, this is the basic test
31 #