mirror of
https://github.com/MariaDB/server.git
synced 2025-03-25 00:18:42 +01:00
main.alter_table_lock could fail with query "'LOCK TABLE t1 WRITE' failed"
Backported fix from MariaDB 10.5
This commit is contained in:
parent
ddb1f7c4e4
commit
915afddba2
2 changed files with 4 additions and 2 deletions
mysql-test/main
|
@ -11,8 +11,6 @@ ERROR 42S02: Table 'test.x' doesn't exist
|
|||
SET SESSION max_session_mem_used= 8192;
|
||||
LOCK TABLE t1 WRITE;
|
||||
ALTER TABLE t1 CHANGE COLUMN IF EXISTS b c INT;
|
||||
Warnings:
|
||||
Note 1054 Unknown column 'b' in 't1'
|
||||
SET SESSION max_session_mem_used = @max_session_mem_used_save;
|
||||
UNLOCK TABLES;
|
||||
DROP TABLE t1;
|
||||
|
|
|
@ -14,9 +14,13 @@ SELECT * FROM t1;
|
|||
ALTER TABLE x MODIFY xx INT;
|
||||
|
||||
SET SESSION max_session_mem_used= 8192;
|
||||
--error 0,ER_OPTION_PREVENTS_STATEMENT
|
||||
LOCK TABLE t1 WRITE;
|
||||
|
||||
--disable_warnings
|
||||
--error 0,ER_OPTION_PREVENTS_STATEMENT
|
||||
ALTER TABLE t1 CHANGE COLUMN IF EXISTS b c INT;
|
||||
--enable_warnings
|
||||
|
||||
SET SESSION max_session_mem_used = @max_session_mem_used_save;
|
||||
UNLOCK TABLES;
|
||||
|
|
Loading…
Add table
Reference in a new issue