mariadb/mysql-test/suite/galera/r/galera_truncate_temporary.result
Brave Galera Crew 36a2a185fe Galera4
2019-01-23 15:30:00 +04:00

74 lines
1.4 KiB
Text

connection node_2;
connection node_1;
CREATE TEMPORARY TABLE t1 (f1 INTEGER PRIMARY KEY) Engine=InnoDB;
INSERT INTO t1 VALUES (1);
TRUNCATE TABLE t1;
SELECT COUNT(*) = 0 FROM t1;
COUNT(*) = 0
1
connection node_2;
SELECT * FROM t1;
ERROR 42S02: Table 'test.t1' doesn't exist
connection node_1;
DROP TABLE t1;
CREATE TABLE t1 (f1 INTEGER) ENGINE=InnoDB;
INSERT INTO t1 VALUES (1);
CREATE TEMPORARY TABLE t1 (f1 INTEGER) ENGINE=InnoDB;
INSERT INTO t1 VALUES (2);
SELECT f1 = 2 FROM t1;
f1 = 2
1
SELECT COUNT(*) = 1 FROM t1;
COUNT(*) = 1
1
TRUNCATE TABLE t1;
SELECT COUNT(*) = 0 FROM t1;
COUNT(*) = 0
1
connection node_2;
SELECT COUNT(*) = 1 FROM t1;
COUNT(*) = 1
1
SELECT f1 = 1 FROM t1;
f1 = 1
1
connection node_1;
DROP TABLE t1;
SELECT COUNT(*) = 1 FROM t1;
COUNT(*) = 1
1
SELECT f1 = 1 FROM t1;
f1 = 1
1
TRUNCATE TABLE t1;
SELECT COUNT(*) = 0 FROM t1;
COUNT(*) = 0
1
connection node_2;
SELECT COUNT(*) = 0 FROM t1;
COUNT(*) = 0
1
connection node_1;
DROP TABLE t1;
connection node_1;
CREATE TABLE t1 (f1 INTEGER) ENGINE=InnoDB;
INSERT INTO t1 VALUES (1);
CREATE TEMPORARY TABLE t1 (f1 INTEGER) ENGINE=InnoDB;
INSERT INTO t1 VALUES (2);
connection node_2;
TRUNCATE TABLE t1;
SELECT COUNT(*) = 0 FROM t1;
COUNT(*) = 0
1
connection node_1;
SELECT f1 = 2 FROM t1;
f1 = 2
1
SELECT COUNT(*) = 1 FROM t1;
COUNT(*) = 1
1
DROP TABLE t1;
SELECT COUNT(*) = 0 FROM t1;
COUNT(*) = 0
1
DROP TABLE t1;