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 -> Re: resetting a sequence

Re: resetting a sequence

From: Arjan van Bentem <avbentem_at_DONT-YOU-DAREdds.nl>
Date: Tue, 23 Mar 1999 19:58:36 +0100
Message-ID: <36f7e45f$0$25398@pascal>


Andrew Babb wrote
> grants were a little bit difficult to recreate

Like you said: using ALTER SEQUENCE would do. Just fetch next_val and change increment_by to a negative value to get to zero in one step. Then fetch next_val again and reset increment_by to 1. We've used something like that. You should also take the cache etc. into account, but no need to drop the sequence and get into problems with your access rights.

Arjan. Received on Tue Mar 23 1999 - 12:58:36 CST

Original text of this message

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