# DROP SEQUENCE statement

The DROP SEQUENCE statement removes the specified sequence generator.

A sequence generator is created by a CREATE SEQUENCE statement.

## Syntax

    DROP SEQUENCE sequenceName RESTRICT

The RESTRICT keyword is required. If a trigger or view references the sequence generator, Derby throws an exception.

Dropping a sequence generator implicitly drops all USAGE privileges that reference it.

## Example

    DROP SEQUENCE order_id RESTRICT;

Parent topic: DROP statements
Related reference
DROP DERBY AGGREGATE statement
DROP FUNCTION statement
DROP INDEX statement
DROP PROCEDURE statement
DROP ROLE statement
DROP SCHEMA statement
DROP SYNONYM statement
DROP TABLE statement
DROP TRIGGER statement
DROP TYPE statement
DROP VIEW statement
SYSCS_UTIL.SYSCS_PEEK_AT_SEQUENCE system function
CREATE SEQUENCE statement
SYSSEQUENCES system table
derby.language.sequence.preallocator