Hi All,
I have created a sequence and my sequence number should not restart with 1 after reaching the maximum value.After reaching the maximum value 100 it should give error.Please reply to this query
please find below the code :
CREATE SEQUENCE pos AS INTEGER START WITH 1 INCREMENT
BY 1 MAXVALUE 100 CYCLE CACHE 5
ALTER SEQUENCE pos RESTART WITH 1 INCREMENT BY 1
MAXVALUE 100 CYCLE CACHE 5
Thanks to all.
I have created a sequence and my sequence number should not restart with 1 after reaching the maximum value.After reaching the maximum value 100 it should give error.Please reply to this query
please find below the code :
CREATE SEQUENCE pos AS INTEGER START WITH 1 INCREMENT
BY 1 MAXVALUE 100 CYCLE CACHE 5
ALTER SEQUENCE pos RESTART WITH 1 INCREMENT BY 1
MAXVALUE 100 CYCLE CACHE 5
Thanks to all.