模式:
create sequence 序列号名
minvalue 最小值
maxvalue 最大值
start with 目前值
increment by 步长
nocache;
举例:
-- Create sequence
create sequence SEQ_ALLACTIVESEARCHINFO
minvalue 1
maxvalue 999999999999999999999999999
start with 15
increment by 1
nocache;
应用:
select seq_allactivesearchinfo.nextval into l_searchid from dual;
alter sequence seq_allactivesearchinfo increment by 200;//200为步长
http://www.ixdba.net/article/88/1571.html 详细内容
ALTER SEQUENCE [schema.]sequence_name option(s)
options:
INCREMENT BY int
MAXVALUE int | NOMAXVALUE
MINVALUE int | NOMINVALUE
CYCLE | NOCYCLE
CACHE int | NOCACHE
ORDER | NOORDER
注意:maxvalue 999999999999999999999999999中最长可以有40个9