FirebirdSQL logo

Example of DROP SEQUENCE

Dropping the EMP_NO_GEN series:
DROP SEQUENCE EMP_NO_GEN;

RECREATE SEQUENCE

Drops a sequence if it exists, and creates a sequence (generator)

Available in

DSQL, ESQL

Syntax
RECREATE {SEQUENCE | GENERATOR} seq_name
  [START WITH start_value]
  [INCREMENT [BY] increment]
Table 1. RECREATE SEQUENCE Statement Parameters
Parameter Description

seq_name

Sequence (generator) name.The maximum length is 63 characters

start_value

Initial value of the sequence

increment

Increment of the sequence (when using NEXT VALUE FOR seq_name);cannot be 0

See [fblangref50-ddl-sequence-create] for the full syntax of CREATE SEQUENCE and descriptions of defining a sequences and its options.

RECREATE SEQUENCE creates or recreates a sequence.If a sequence with this name already exists, the RECREATE SEQUENCE statement will try to drop it and create a new one.Existing dependencies will prevent the statement from executing.