| 1 |
******************************* |
| 2 |
* basic concurent online alter test |
| 3 |
******************************* |
| 4 |
* With Commit |
| 5 |
******************************* |
| 6 |
CREATE TABLE t1 (a INT UNSIGNED, |
| 7 |
b INT UNSIGNED not null, |
| 8 |
primary key(a)) ENGINE NDB; |
| 9 |
begin; |
| 10 |
update t1 set b = b + 1 where a = 1; |
| 11 |
ALTER TABLE t1 algorithm=copy, ADD c CHAR(19); |
| 12 |
ERROR HY000: Lock wait timeout exceeded; try restarting transaction |
| 13 |
commit; |
| 14 |
ALTER TABLE t1 algorithm=copy, ADD c CHAR(19); |
| 15 |
create unique index b_unq on t1(b) using hash; |
| 16 |
ERROR 23000: Can't write, because of unique constraint, to table 't1' |
| 17 |
update t1 set b = b - 1 where a = 1; |
| 18 |
create unique index b_unq on t1(b) using hash; |
| 19 |
DROP TABLE t1; |