NAME
DROP INDEX - 删除一个索引
SYNOPSIS
DROP INDEX name [, ...] [ CASCADE | RESTRICT ]
DESCRIPTION 描述
DROP INDEX 从数据库中删除一个现存的索引。 要执行这个命令,你必须是索引的所有者。
PARAMETERS 参数
- name
要删除的索引名(可以有模式修饰)。- CASCADE
自动删除依赖于该索引的对象。- RESTRICT
如果有依赖对象存在,则拒绝删除该索引。这个是缺省。
EXAMPLES 例子
此命令将删除title_idx 索引:
DROP INDEX title_idx;
COMPATIBILITY 兼容性
DROP INDEX 是 PostgreSQL 语言扩展。 在 SQL 标准里没有索引的规定。
SEE ALSO 参见
CREATE INDEX [create_index(7)]
#p#
NAME
DROP INDEX - remove an index
SYNOPSIS
DROP INDEX name [, ...] [ CASCADE | RESTRICT ]
DESCRIPTION
DROP INDEX drops an existing index from the database system. To execute this command you must be the owner of the index.
PARAMETERS
- name
- The name (optionally schema-qualified) of an index to remove.
- CASCADE
- Automatically drop objects that depend on the index.
- RESTRICT
- Refuse to drop the index if any objects depend on it. This is the default.
EXAMPLES
This command will remove the index title_idx:
DROP INDEX title_idx;
COMPATIBILITY
DROP INDEX is a PostgreSQL language extension. There are no provisions for indexes in the SQL standard.
SEE ALSO
CREATE INDEX [create_index(7)]