How do I reset a sequence in Oracle?

后端 未结 18 1501
天命终不由人
天命终不由人 2020-11-22 05:09

In PostgreSQL, I can do something like this:

ALTER SEQUENCE serial RESTART WITH 0;

Is there an Oracle equivalent?

18条回答
  •  不知归路
    2020-11-22 05:41

    Jezus, all this programming for just an index restart... Perhaps I'm an idiot, but for pre-oracle 12 (which has a restart feature), what is wrong with a simpel:

    drop sequence blah;
    create sequence blah 
    

    ?

提交回复
热议问题