Creation of serial types does not accept negative numbers #6665
Last updated: 2019-01-14 17:29:14 +0100
Date: 2018-12-06 13:46:06 +0100
User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/70.0.3538.110 Safari/537.36
From https://www.monetdb.org/Documentation/Manuals/SQLreference/SerialTypes I see that sequence parameters are defined as "non-zero" values.
That raises a few questions for me:
sql>create sequence myseq as integer start with 0 increment by 1;
sql>create sequence myseq as integer start with -1 increment by 1;
Notice that the error reports "sqlINT" as expected. As far as I can tell, sqlINT includes negative integers.
sql>create sequence myseq as integer start with 1 increment by -1;
Again, the error is misleading.
Date: 2018-12-06 13:47:09 +0100
The above applies of course also for the syntax: GENERATED ALWAYS AS IDENTITY [ '(' seq_params ')' ]
Date: 2018-12-06 14:27:25 +0100
I just checked the SQL standard, and indeed negative values for sequences are allowed, as well increments. I'm working to add this feature.
Date: 2018-12-06 16:46:23 +0100
For complete details, see https//devmonetdborg/hg/MonetDB?cmd=changeset;node=b2e362c68b8b
Date: 2018-12-11 14:56:39 +0100
I have updated the text on the references web page and the help text that you get in mclient using \help.
The text was updated successfully, but these errors were encountered: