You can use the DROP SEQUENCE statement to drop a sequence. This topic describes how to drop a sequence.
Syntax
DROP SEQUENCE [schema. ] sequence_name;
Parameters
| Parameter | Description |
|---|---|
| schema. | The schema where the sequence to be dropped is located. If schema. is not specified, the sequence to be dropped is located in the schema of the currently logged-on user. |
| sequence_name | The name of the sequence to be dropped. |
Examples
Drop the sequence named
seq1.obclient> DROP SEQUENCE seq1; Query OK, 0 rows affectedQuery the seq1 sequence.
obclient> SELECT sequence_name,max_value FROM oceanbase.__all_sequence_object WHERE sequence_name='seq1'; Empty set