# DROP ROLE
#### 功能描述
删除一个角色。
#### 语法格式
```
DROP ROLE [ IF EXISTS ] role_name [, ...];
```
![](https://support.huaweicloud.com/distributed-ref-v10-gaussdb/figure/zh-cn_image_0000002793788327.png "点击放大")
#### 参数说明
- **IF EXISTS**
  判断指定的角色是否存在。
  - 如果指定的角色存在，则删除成功。
  
  - 如果指定的角色不存在，不会进行删除操作，仅产生一个NOTICE提示，用于告知指定的角色不存在。
   
- **role_name**
  需要删除的角色名称。
  取值范围：已存在的角色。
  
 
#### 示例
```
--创建角色role11。
gaussdb=# CREATE ROLE role11  PASSWORD '********';
CREATE ROLE
--删除role11角色。
gaussdb=# DROP ROLE IF EXISTS role11;
DROP ROLE
--删除不存在的角色role12。
gaussdb=# DROP ROLE IF EXISTS role12;
NOTICE:  role "role12" does not exist, skipping
DROP ROLE
```
#### 相关链接
[CREATE ROLE](https://support.huaweicloud.com/distributed-ref-v10-gaussdb/gaussdb-08-0264.html)，[ALTER ROLE](https://support.huaweicloud.com/distributed-ref-v10-gaussdb/gaussdb-08-0203.html)，[SET ROLE](https://support.huaweicloud.com/distributed-ref-v10-gaussdb/gaussdb-08-0398.html)
