RE: How do we set new value for a SEQUENCE?
From: Gorm Larsen <gorm_larsen_at_vestjyde.dk>
Date: Wed, 23 Feb 2000 00:15:38 +0100
Message-ID: <MPG.131d3706fa8720ee9896a4_at_valhal>
Date: Wed, 23 Feb 2000 00:15:38 +0100
Message-ID: <MPG.131d3706fa8720ee9896a4_at_valhal>
In article <qJDs4.359$y3.188314624_at_newsb.telia.net>, ingvar.larsson_at_gilsupport.
se says...
> Hi you helpful people out there!
> CREATE PROCEDURE XREINIT (NEWVAL IN NUMBER) AS
> I NUMBER;
> BEGIN
> SELECT X.CURRVAL INTO I FROM dual;
Being a newbie I may be wrong on this, but I'm not sure you can select currval whitout having selected next_val first, so if you've just restarted your server the procedure probably won't work. But in your case it shouldn't be a problem to start your procedure with a select next_val
HIAR (Hope I am right) :-)
-- Gorm LarsenReceived on Wed Feb 23 2000 - 00:15:38 CET