Reports information about a particular group or about all groups in the current database.
sp_helpgroup [grpname]
sp_helpgroup
Group_name Group_id --------------- -------- hackers 16384 public 0
sp_helpgroup hackers
Group_name Group_id Users_in_group Userid ----------- --------- -------------- ------ hackers 16384 ann 4 hackers 16384 judy 3
To get a report on the default group, “public,” enclose the name “public” in single or double quotes (“public” is a reserved word).
If there are no members in the specified group, sp_helpgroup displays the header, but lists no users, as follows:
Group_name Group_id Users_in_group Userid ----------- --------- -------------- ------
See also grant, revoke in Reference Manual: Commands.
Any user can execute sp_helpgroup. Permission checks do not differ based on the granular permissions settings.
Values in event and extrainfo columns from the sysaudits table are:
Information | Values |
---|---|
Event | 38 |
Audit option | exec_procedure |
Command or access audited | Execution of a procedure |
Information in extrainfo |
|