mirror of
https://github.com/MariaDB/server.git
synced 2025-01-16 12:02:42 +01:00
35 lines
691 B
Text
35 lines
691 B
Text
connection node_2;
|
|
connection node_1;
|
|
CREATE DATABASE d1;
|
|
CREATE TABLE d1.t1(f1 INTEGER) ENGINE=InnoDB;
|
|
CREATE DATABASE d2;
|
|
CREATE TABLE d2.t1(f1 INTEGER PRIMARY KEY) ENGINE=InnoDB;
|
|
connection node_1;
|
|
SET AUTOCOMMIT=OFF;
|
|
START TRANSACTION;
|
|
INSERT INTO d1.t1 VALUES (1);
|
|
connection node_2;
|
|
SET AUTOCOMMIT=OFF;
|
|
START TRANSACTION;
|
|
INSERT INTO d2.t1 VALUES (1);
|
|
connection node_1;
|
|
COMMIT;
|
|
connection node_2;
|
|
COMMIT;
|
|
SELECT COUNT(*) = 1 FROM d1.t1;
|
|
COUNT(*) = 1
|
|
1
|
|
SELECT COUNT(*) = 1 FROM d2.t1;
|
|
COUNT(*) = 1
|
|
1
|
|
connection node_1;
|
|
SELECT COUNT(*) = 1 FROM d1.t1;
|
|
COUNT(*) = 1
|
|
1
|
|
SELECT COUNT(*) = 1 FROM d2.t1;
|
|
COUNT(*) = 1
|
|
1
|
|
DROP TABLE d1.t1;
|
|
DROP TABLE d2.t1;
|
|
DROP DATABASE d1;
|
|
DROP DATABASE d2;
|