Use FLUSH SEQUENCE immediately after you start Extract for the first time during an initial synchronization or a re-synchronization. This command updates an Oracle sequence so that initial redo records are available at the time that Extract starts to capture transaction data. Normally, redo is not generated until the current cache is exhausted. The flush gives Replicat an initial start point with which to synchronize to the correct sequence value on the target system. From then on, Extract can use the redo that is associated with the usual cache reservation of sequence values.


  1. The following Oracle procedures are used by FLUSH SEQUENCE:

    Table 1-18 Procedures That Support FLUSH SEQUENCE

    Database Procedure User and Privileges



    Grants EXECUTE to the owner of the Oracle GoldenGate DDL objects, or other selected user if not using DDL support.



    Grants EXECUTE to the Oracle GoldenGate Replicat user.

    The sequence.sql script installs these procedures. Normally, this script is run as part of the Oracle GoldenGate installation process, but make certain that was done before using FLUSH SEQUENCE. If sequence.sql was not run, the flush fails and an error message similar to the following is generated:

    Cannot flush sequence {0}. Refer to the Oracle GoldenGate for Oracle 
    documentation for instructions on how to set up and run the sequence.sql 
    script. Error {1}.
  2. The GLOBALS file must contain a GGSCHEMA parameter that specifies the schema in which the procedures are installed. This user must have CONNECT, RESOURCE, and DBA privileges.

  3. Before using FLUSH SEQUENCE, issue the DBLOGIN command as the database user that has EXECUTE privilege on the updateSequence procedure. If logging into a multitentant container database, log into the pluggable database that contains the sequence that is to be flushed.


For full instructions on configuring Oracle GoldenGate to support sequences, see Installing and Configuring Oracle GoldenGate for Oracle Database.


FLUSH SEQUENCE owner.sequence

The owner and name of an Oracle sequence. The schema name cannot be null. You can use an asterisk (*) wildcard for the sequence name but not for the owner name.