Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> possible to 'reset' a sequence by a stored procedure?

possible to 'reset' a sequence by a stored procedure?

From: Stefan Röhle <roehle_at_uni-mainz.de>
Date: Fri, 19 Dec 2003 13:32:49 +0100
Message-ID: <brur5i$c7h$1@bambi.zdv.Uni-Mainz.DE>


Hi,

I need to 'reset' a stored procedure each time the year changes (2003->2004). So what I usually do is a manual

drop sequence seq_vorgangs_nr_neu;

create sequence seq_vorgangs_nr_neu
increment by 1
maxvalue 2999
start with 201
nocycle
nocache;

Since it is not possible to do this in a stored procedure (or is it possible now?) I am looking for a way to get this done automatially.
Is there any other way than using a scripting language?

Stefan Received on Fri Dec 19 2003 - 06:32:49 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US