Issue Details (XML | Word | Printable)

Key: CORE-6365
Type: Bug Bug
Status: Open Open
Priority: Major Major
Assignee: Unassigned
Reporter: Pavel Zotov
Votes: 0
Watchers: 2
Operations

If you were logged in you would be able to see more operations.
Firebird Core

Values less than -2147483648 can not be spicified in the INCREMENT BY clause a column defined as GENERATED AS IDENTITY

Created: 13/Jul/20 10:52 AM   Updated: 13/Jul/20 11:13 AM
Component/s: Engine
Affects Version/s: 4.0 Beta 2
Fix Version/s: None

QA Status: No test


 Description  « Hide
recreate table test0( id bigint generated by default as identity (start with 9223372036854775807 increment by -2147483647) );

recreate table test0( id bigint generated by default as identity (start with 9223372036854775807 increment by -2147483648) );

recreate table test0( id bigint generated by default as identity (start with 9223372036854775807 increment by -2147483649) );

Second and third statements fail with:
=======
Statement failed, SQLSTATE = 42000
Dynamic SQL Error
-SQL error code = -104
-Token unknown - line 1, column 113
-2147483648 (-21474836489)
=======

Checked on 4.0.0.2104


 All   Comments   Change History   Subversion Commits      Sort Order: Ascending order - Click to sort in descending order
Mark Rotteveel added a comment - 13/Jul/20 11:12 AM - edited
This sounds like an edge case that is unlikely to ever be relevant in real usage. Or to phrase differently, limiting the increment to an INT (or even a SMALLINT) should be sufficient for normal usage. There is no reason to extend it to a BIGINT.