Skip to content

Latest commit

 

History

History
55 lines (37 loc) · 990 Bytes

sql-statement-drop-sequence.md

File metadata and controls

55 lines (37 loc) · 990 Bytes
title summary aliases
DROP SEQUENCE
TiDB 数据库中 DROP SEQUENCE 的使用概况。
/docs-cn/dev/sql-statements/sql-statement-drop-sequence/
/docs-cn/dev/reference/sql/statements/drop-sequence/

DROP SEQUENCE

DROP SEQUENCE 语句用于删除序列对象。

语法图

DropSequenceStmt ::=
    'DROP' 'SEQUENCE' IfExists TableNameList

IfExists ::= ( 'IF' 'EXISTS' )?

TableNameList ::=
    TableName ( ',' TableName )*

TableName ::=
    Identifier ('.' Identifier)?

示例

{{< 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 兼容性

该语句是 TiDB 的扩展,序列的实现借鉴自 MariaDB。

另请参阅