DROP SEQUENCE
April 15, 2024 ยท View on GitHub
The DROP SEQUENCE statement drops the sequence object in TiDB.
Synopsis
DropSequenceStmt ::=
'DROP' 'SEQUENCE' IfExists TableNameList
IfExists ::= ( 'IF' 'EXISTS' )?
TableNameList ::=
TableName ( ',' TableName )*
TableName ::=
Identifier ('.' Identifier)?
Examples
{{< copyable "sql" >}}
DROP SEQUENCE seq;
Query OK, 0 rows affected (0.10 sec)
{{< copyable "sql" >}}
DROP SEQUENCE seq, seq2;
Query OK, 0 rows affected (0.03 sec)
MySQL compatibility
This statement is a TiDB extension. The implementation is modeled on sequences available in MariaDB.