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 -> Confusion About Sequence

Confusion About Sequence

From: Khurram <oraware_at_gmail.com>
Date: 26 Apr 2006 02:49:57 -0700
Message-ID: <1146044997.544377.285540@y43g2000cwc.googlegroups.com>


hi

I read something about seqence there but still not clear please give some light on it

http://download-west.oracle.com/docs/cd/B10501_01/server.920/a96540/sql_elements6a.htm#4062

Within a single SQL statement containing a reference to NEXTVAL, Oracle increments the sequence only once:

   For each row returned by the outer query block of a SELECT statement. Such a query block

   can appear in the following places:
    -A top-level SELECT statement
   -An INSERT ... SELECT statement (either single-table or multi-table). For a multi-table insert, the reference

    to NEXTVAL must appear in the VALUES clause, and the sequence is updated once for each row

    returned by the subquery, even though NEXTVAL may be referenced in multiple branches of the

    multi-table insert.

Thanx in advance

Khurram Received on Wed Apr 26 2006 - 04:49:57 CDT

Original text of this message

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