阅读(3771) (12)

PostgreSQL CREATE GROUP

2021-08-23 14:27:06 更新

CREATE GROUP — 定义一个新的数据库角色

大纲

CREATE GROUP name [ [ WITH ] option [ ... ] ]

其中 option 可以是:

      SUPERUSER | NOSUPERUSER
    | CREATEDB | NOCREATEDB
    | CREATEROLE | NOCREATEROLE
    | INHERIT | NOINHERIT
    | LOGIN | NOLOGIN
    | REPLICATION | NOREPLICATION
    | BYPASSRLS | NOBYPASSRLS
    | CONNECTION LIMIT connlimit
    | [ ENCRYPTED ] PASSWORD 'password' | PASSWORD NULL
    | VALID UNTIL 'timestamp'
    | IN ROLE role_name [, ...]
    | IN GROUP role_name [, ...]
    | ROLE role_name [, ...]
    | ADMIN role_name [, ...]
    | USER role_name [, ...]
    | SYSID uid

描述

CREATE GROUP现在是 CREATE ROLE的一种别名。

兼容性

在 SQL 标准中没有CREATE GROUP语句。