mirror of
https://github.com/MariaDB/server.git
synced 2025-01-19 05:22:25 +01:00
31 lines
959 B
Text
31 lines
959 B
Text
|
CREATE TABLE rand_table (f1 FLOAT);
|
||
|
CREATE TABLE t1 (f1 INTEGER PRIMARY KEY, f2 CHAR(1));
|
||
|
INSERT INTO t1 VALUES (1, 'a');
|
||
|
INSERT INTO t1 VALUES (2, 'a');
|
||
|
SET AUTOCOMMIT=ON;
|
||
|
START TRANSACTION;
|
||
|
UPDATE t1 SET f2 = 'b' WHERE f1 = 1;
|
||
|
SELECT * FROM t1 WHERE f1 = 2 FOR UPDATE;
|
||
|
f1 f2
|
||
|
2 a
|
||
|
SET GLOBAL wsrep_provider_options = 'dbug=d,commit_monitor_enter_sync';
|
||
|
COMMIT;;
|
||
|
SET SESSION wsrep_sync_wait = 0;
|
||
|
SET SESSION wsrep_on = 0;
|
||
|
SET SESSION wsrep_on = 1;
|
||
|
UPDATE t1 SET f2 = 'c' WHERE f1 = 2;
|
||
|
SET GLOBAL wsrep_provider_options = 'dbug=';
|
||
|
SET GLOBAL wsrep_provider_options = 'signal=commit_monitor_enter_sync';
|
||
|
SELECT TIMEDIFF(SYSDATE(), NOW()) < 2;
|
||
|
TIMEDIFF(SYSDATE(), NOW()) < 2
|
||
|
1
|
||
|
INSERT INTO rand_table VALUES (RAND()),(RAND()),(RAND()),(RAND()),(RAND());
|
||
|
INSERT INTO rand_table VALUES (RAND()),(RAND()),(RAND()),(RAND()),(RAND());
|
||
|
SELECT COUNT(DISTINCT f1) = 10 FROM rand_table;
|
||
|
COUNT(DISTINCT f1) = 10
|
||
|
1
|
||
|
wsrep_local_replays
|
||
|
1
|
||
|
DROP TABLE t1;
|
||
|
DROP TABLE rand_table;
|