修改一个oracle序列的当前值

declare
   LastValue integer;
begin
   loop
select SEQ_CONTRACT.currval into LastValue from dual;
    exit when LastValue >= 160 - 1; ---- 160是设置的值
    select SEQ_CONTRACT.nextval into LastValue from dual;
   end loop;
end;

你可能感兴趣的:(修改一个oracle序列的当前值)