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

Home -> Community -> Usenet -> c.d.o.server -> Getting currval from a sequence with out incrementing nextval

Getting currval from a sequence with out incrementing nextval

From: Bonk <bonk.brennan_at_gmail.com>
Date: 3 Mar 2006 14:32:55 -0800
Message-ID: <1141425175.303800.98530@u72g2000cwu.googlegroups.com>


Kind of a dumb question is there a good way in 10.2G to get the current value of a sequence number with first select thing the next value? Our issue is that we have a database that caches a large chunk of numbers on our sequences, and it appears that the column LAST_NUMBER on user_sequences (or dba_sequences) has the last value of the cached numbers.

I would like to compare the current value of the sequence to the associated primary keys so that I can determine that I do not have a "unique key constraint" without burning a next value first. Received on Fri Mar 03 2006 - 16:32:55 CST

Original text of this message

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