| 1 |
-- source include/have_maria.inc |
| 2 |
--source include/have_binlog_format_statement.inc |
| 3 |
|
| 4 |
drop table if exists t1; |
| 5 |
|
| 6 |
--echo # |
| 7 |
--echo # MDEV-7314 |
| 8 |
--echo # Concurrent "INSERT INTO table SELECT MAX(id)+1 FROM table" are |
| 9 |
--echo # hitting deadlocks on Aria tables using ROW_FORMAT=PAGE |
| 10 |
--echo # |
| 11 |
|
| 12 |
create table t1 (pk int primary key) engine=Aria; |
| 13 |
insert into t1 values (1); |
| 14 |
|
| 15 |
send insert into t1 select sleep(2)+1 from t1; |
| 16 |
|
| 17 |
--connect (con1,localhost,root,,) |
| 18 |
|
| 19 |
--error 0,1062 |
| 20 |
insert into t1 select 2 from t1; |
| 21 |
|
| 22 |
--connection default |
| 23 |
--error 0,1062 |
| 24 |
--reap |
| 25 |
|
| 26 |
select * from t1; |
| 27 |
drop table t1; |