alter_group.7

来自「PostgreSQL 8.2中增加了很多企业用户所需要的功能和性能上的提高,其开」· 7 代码 · 共 65 行

7
65
字号
.\\" auto-generated by docbook2man-spec $Revision: 1.1.1.1 $.TH "ALTER GROUP" "" "2008-01-03" "SQL - Language Statements" "SQL Commands".SH NAMEALTER GROUP \- change role name or membership.SH SYNOPSIS.sp.nfALTER GROUP \fIgroupname\fR ADD USER \fIusername\fR [, ... ]ALTER GROUP \fIgroupname\fR DROP USER \fIusername\fR [, ... ]ALTER GROUP \fIgroupname\fR RENAME TO \fInewname\fR.sp.fi.SH "DESCRIPTION".PP\fBALTER GROUP\fR changes the attributes of a user group.This is an obsolete command, though still accepted for backwardscompatibility, because groups (and users too) have been superseded by themore general concept of roles..PPThe first two variants add users to a group or remove them from a group.(Any role can play the part of either a ``user'' or a``group'' for this purpose.) These variants are effectivelyequivalent to granting or revoking membership in the role named as the``group''; so the preferred way to do this is to useGRANT [\fBgrant\fR(7)] orREVOKE [\fBrevoke\fR(7)]..PPThe third variant changes the name of the group. This is exactlyequivalent to renaming the role with ALTER ROLE [\fBalter_role\fR(7)]..SH "PARAMETERS".TP\fB\fIgroupname\fB\fRThe name of the group (role) to modify..TP\fB\fIusername\fB\fRUsers (roles) that are to be added to or removed from the group.The users must already exist; \fBALTER GROUP\fR does notcreate or drop users..TP\fB\fInewname\fB\fRThe new name of the group..SH "EXAMPLES".PPAdd users to a group:.sp.nfALTER GROUP staff ADD USER karl, john;.sp.fiRemove a user from a group:.sp.nfALTER GROUP workers DROP USER beth;.sp.fi.SH "COMPATIBILITY".PPThere is no \fBALTER GROUP\fR statement in the SQLstandard..SH "SEE ALSO"GRANT [\fBgrant\fR(7)], REVOKE [\fBrevoke\fR(l)], ALTER ROLE [\fBalter_role\fR(l)]

⌨️ 快捷键说明

复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?