Details
-
Bug
-
Status: Confirmed (View Workflow)
-
Major
-
Resolution: Unresolved
-
11.8.2
-
None
Description
It looks like the skip locked clause is affected by a SET @@SESSION.innodb_lock_wait_timeout = 0.
Assume the following table and data:
create table details(id int not null primary key, name varchar(255)); |
insert into details values (1, 'a'); |
Now comes along transaction 1:
begin; |
select name from details where id=1 for update; |
Notice, no commit yet.
And then comes transaction 2:
SET @@SESSION.innodb_lock_wait_timeout = 0; |
begin; |
select name from details where id=1 for update skip locked; |
Transaction 2 will fail saying Got error 1 "Operation not permitted" during COMMIT.
Attachments
Issue Links
- relates to
-
MDEV-13115 Implement SELECT [FOR UPDATE|LOCK IN SHARED MODE] SKIP LOCKED
-
- Closed
-