Displays the permissions of a fixed server role. sp_srvrolepermission returns correct information in SQL Server 2000. The output does not reflect changes to the permissions hierarchy that were implemented in SQL Server 2005. For more information, see Permissions (Database Engine).
Important
|
|---|
|
This feature will be removed in a future version of Microsoft SQL Server. Avoid using this feature in new development work, and plan to modify applications that currently use this feature. |
sp_srvrolepermission [ [ @srvrolename = ] 'role']
0 (success) or 1 (failure)
|
Column name |
Data type |
Description |
|---|---|---|
|
ServerRole |
sysname |
Name of a fixed server role |
|
Permission |
sysname |
Permission associated with ServerRole |
The permissions listed include the Transact-SQL statements that can be executed, and other special activities that can be performed by members of the fixed server role. To display a list of the fixed server roles, execute sp_helpsrvrole.
The sysadmin fixed server role has the permissions of all the other fixed server roles.
Requires membership in the public role.
The following query returns the permissions associated with the sysadmin fixed server role.
EXEC sp_srvrolepermission 'sysadmin'; GO
Important