DROP DOMAIN

用于删除域的SQL命令

DROP DOMAIN 是一个用于删除的 DDL 命令。

DROP DOMAINPostgreSQL 7.3 中添加。

变更历史

示例

尝试删除正在使用的域

postgres=# DROP DOMAIN git_sha1 ;
ERROR:  cannot drop type git_sha1 because other objects depend on it
DETAIL:  column commit_ref of table repo_commit_ref depends on type git_sha1
HINT:  Use DROP ... CASCADE to drop the dependent objects too.

删除正在使用的域

postgres=# DROP DOMAIN git_sha1 CASCADE;
NOTICE:  drop cascades to column commit_ref of table repo_commit_ref
DROP DOMAIN

分类

数据类型, DDL, , SQL命令

另请参阅

CREATE DOMAIN, ALTER DOMAIN

反馈

对于 "DROP DOMAIN" 的任何评论、建议或更正,请在此 提交