Re: Sequence trouble in V6

From: Craig Nirosky <craign_at_telxon.mis.telxon.com>
Date: Sat, 17 Apr 1993 19:12:18 GMT
Message-ID: <1993Apr17.191218.976_at_telxon.mis.telxon.com>


In article <1qn1p3$e69_at_gabriel.keele.ac.uk> csa09_at_keele.ac.uk (Paul Singleton) writes:
>
>There are two potential ways of getting this value from a sequence 'SEQ1':
>
> SQL> select SEQ1.CURRVAL from DUAL;
> ERROR:
> ORA-08002: SEQ1.CURRVAL is not yet defined in this session
>
>which is no use unless I've already drawn a sequence number "in the
>current session", e.g.
>

Try looking at the LAST_NUMBER field in the data dictionary table USER_SEQUENCES. I am not sure if this field contains the last number or the next number.

-- 
 cniro_at_telxon.com                               Craig Nirosky, MIS Dept.
 (216) 867-3700 x3651                           Telxon Corporation
                                                P.O. Box 5582
 "Hey Buddy, can you paradigm?"                 Akron, OH  44334-0582
Received on Sat Apr 17 1993 - 21:12:18 CEST

Original text of this message