mirror of
https://github.com/MariaDB/server.git
synced 2025-07-30 16:24:05 +03:00
MDEV-15732: Assertion `next_free_value % real_increment == offset && next_free_value >= reserved_until' failed in sequence_definition::adjust_values upon SETVAL for sequence with INCREMENT 0
there was a problem with "next_free_value >= reserved_until" condition: SEQUENCE::set_value handle next_free_value & reserved_until after adjust_values() call, so it is incorect to put assert on it in adjust_values()
This commit is contained in:
@ -137,3 +137,20 @@ SELECT SETVAL(s1,10);
|
||||
DROP SEQUENCE s1;
|
||||
--enable_ps_protocol
|
||||
--disable_metadata
|
||||
|
||||
--echo #
|
||||
--echo # MDEV-15732: Assertion `next_free_value % real_increment == offset &&
|
||||
--echo # next_free_value >= reserved_until' failed in
|
||||
--echo # sequence_definition::adjust_values upon SETVAL for sequence with
|
||||
--echo # INCREMENT 0
|
||||
--echo #
|
||||
|
||||
CREATE SEQUENCE s INCREMENT 0;
|
||||
SELECT NEXTVAL(s);
|
||||
SELECT SETVAL(s, 10);
|
||||
|
||||
# Cleanup
|
||||
DROP SEQUENCE s;
|
||||
|
||||
|
||||
--echo # End of 10.3 tests
|
||||
|
Reference in New Issue
Block a user