mirror of
https://github.com/MariaDB/server.git
synced 2025-07-29 05:21:33 +03:00
MDEV-12930 Testing SEQUENCE object
Fixed the following things from the above MDEV: - Ensure the user has INSERT privilege when generating new sequence values with NEXT VALUE FOR or SETVAL() - Fixed bug in InnoDB when generating several sequence values in one statement - Ensure that read_set is up to date before calling ha_sequence::ha_write_row() - This is only a potential bug with storage engines that trusts the column maps completely
This commit is contained in:
@ -90,3 +90,30 @@ LOCK TABLES s1 WRITE;
|
||||
insert into s1 values (1,1,9223372036854775806, 1, 1, 1000, 0, 0);
|
||||
UNLOCK TABLES;
|
||||
drop table s1;
|
||||
|
||||
--echo #
|
||||
--echo # Many sequence calls with innodb
|
||||
--echo #
|
||||
|
||||
create sequence s1 cache=1000 engine=innodb;
|
||||
start transaction;
|
||||
select count(nextval(s1)) from seq_1_to_2000;
|
||||
commit;
|
||||
select * from s1;
|
||||
drop sequence s1;
|
||||
|
||||
create sequence s1 cache=1000 engine=innodb;
|
||||
start transaction;
|
||||
select count(nextval(s1)) from seq_1_to_2000;
|
||||
|
||||
connect (addconroot, localhost, root,,);
|
||||
connection addconroot;
|
||||
start transaction;
|
||||
select count(nextval(s1)) from seq_1_to_2000;
|
||||
select * from s1;
|
||||
commit;
|
||||
disconnect addconroot;
|
||||
connection default;
|
||||
select * from s1;
|
||||
commit;
|
||||
drop sequence s1;
|
||||
|
Reference in New Issue
Block a user