4 ALTER GROUP — change role name or membership
8 ALTER GROUP role_specification ADD USER user_name [, ... ]
9 ALTER GROUP role_specification DROP USER user_name [, ... ]
11 where role_specification can be:
18 ALTER GROUP group_name RENAME TO new_name
22 ALTER GROUP changes the attributes of a user group. This is an obsolete
23 command, though still accepted for backwards compatibility, because
24 groups (and users too) have been superseded by the more general concept
27 The first two variants add users to a group or remove them from a
28 group. (Any role can play the part of either a “user” or a “group” for
29 this purpose.) These variants are effectively equivalent to granting or
30 revoking membership in the role named as the “group”; so the preferred
31 way to do this is to use GRANT or REVOKE. Note that GRANT and REVOKE
32 have additional options which are not available with this command, such
33 as the ability to grant and revoke ADMIN OPTION, and the ability to
36 The third variant changes the name of the group. This is exactly
37 equivalent to renaming the role with ALTER ROLE.
42 The name of the group (role) to modify.
45 Users (roles) that are to be added to or removed from the group.
46 The users must already exist; ALTER GROUP does not create or
50 The new name of the group.
55 ALTER GROUP staff ADD USER karl, john;
57 Remove a user from a group:
58 ALTER GROUP workers DROP USER beth;
62 There is no ALTER GROUP statement in the SQL standard.
66 GRANT, REVOKE, ALTER ROLE