comdb2
comdb2 copied to clipboard
Add support for sequences on existing column
null=yes should not be needed in this case (see first commit) Adds csc2 and ddl support
Provided that:
- The col the sequence is added on is the leftmost field in some key
- The key can be added in the same schema change as adding nextsequence
- Or, an existing valid key can even be removed in the same schema change as adding nextsequence
- It is not a partial key
- Nullsort low is enabled
- The key is ascending
- If the key is empty or the highest value in the key is NULL, start sequence from 0
Also note: in strict mode you can convert a column from int b to longlong b dbstore=nextsequence and this is fine even though the old column is only an int
cdb2test Jun 25 15:22:45 2024 in-comdb2db existing_auto_inc.R20240625.4
THANK YOU MARK!!