mirror of
https://github.com/MariaDB/server.git
synced 2025-01-26 00:34:18 +01:00
24 lines
747 B
Text
24 lines
747 B
Text
|
Tests of syncronization of stored procedure execution.
|
||
|
#
|
||
|
# Bug#48157: crash in Item_field::used_tables
|
||
|
#
|
||
|
CREATE TABLE t1 AS SELECT 1 AS a, 1 AS b;
|
||
|
CREATE TABLE t2 AS SELECT 1 AS a, 1 AS b;
|
||
|
CREATE PROCEDURE p1()
|
||
|
BEGIN
|
||
|
UPDATE t1 JOIN t2 USING( a, b ) SET t1.b = 1, t2.b = 1;
|
||
|
END|
|
||
|
LOCK TABLES t1 WRITE, t2 WRITE;
|
||
|
SET DEBUG_SYNC = 'multi_update_reopen_tables SIGNAL parked WAIT_FOR go';
|
||
|
CALL p1();
|
||
|
DROP TABLE t1, t2;
|
||
|
SET DEBUG_SYNC = 'now WAIT_FOR parked';
|
||
|
CREATE TABLE t1 AS SELECT 1 AS a, 1 AS b;
|
||
|
CREATE TABLE t2 AS SELECT 1 AS a, 1 AS b;
|
||
|
SET DEBUG_SYNC = 'now SIGNAL go';
|
||
|
# Without the DEBUG_SYNC supplied in the same patch as this test in the
|
||
|
# code, this test statement will hang.
|
||
|
DROP TABLE t1, t2;
|
||
|
DROP PROCEDURE p1;
|
||
|
SET DEBUG_SYNC = 'RESET';
|