The Oracle Sequence Function assigns a value to the destination
column by using an Oracle Sequence.
schema.seqname.NEXTVAL
[INCL_UPD]
- schema
- Qualifier for the Oracle Sequence name.
- seqname
- Name of the Oracle Sequence that assigns sequential
values.
- NEXTVAL
- Keyword that inserts the next Oracle value into
the destination column.
- INCL_UPD
- Optional keyword that updates a sequence value
assigned to a column when rows are updated during an insert process.
If not specified (default), the column value remains unchanged when
the row is updated.
- You can use the Oracle Sequence Function to assign
unique sequential values for rows to be inserted into an Oracle database.
- The Oracle Sequence Function is valid when used
in a column map for insert or load processing, but is not valid for
convert processing.
- If rows are updated in an insert (update/insert)
process and the destination column is part of the primary key, the
column value remains unchanged when the row in the destination table
is updated. To use Oracle Sequence when performing an update/insert,
include INCL_UPD with the function.
- During a load process, the process uses the Oracle
Sequence Function to assign a new value to each destination row. The
Load calls the DBMS to obtain these values. If you choose not to run
the Oracle Loader, these sequence values are never used.
Example 1
To
assign a sequential value to increment customer numbers, where the
name of the Oracle Sequence is schema.numeven, specify:
schema.numeven.NEXTVAL
Example 2
To
expand the first example and update an existing sequence value, specify:
schema.numeven.NEXTVAL(INCL_UPD)