Udostępnij za pośrednictwem


sp_srvrolepermission (Transact-SQL)

Wyświetla uprawnienia stała rola serwera. sp_srvrolepermission zwraca poprawne informacjeSQL Server 2000. Dane wyjściowe nie uwzględnia zmian do hierarchii uprawnień, które zostały wykonane w SQL Server 2005. Aby uzyskać więcej informacji zobacz Permissions of Fixed Server Roles (Database Engine).

Important noteImportant Note:

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.

Topic link iconKonwencje składni języka Transact-SQL

sp_srvrolepermission [ [ @srvrolename = ] 'role']

Argumenty

  • [ @srvrolename = ] 'role'
    Is the name of the fixed server role for which permissions are returned.role is sysname, with a default of NULL.If no role is specified, the permissions for all fixed server roles are returned.role can have one of the following values.

    Wartość

    Description

    sysadmin

    Administratorzy systemu

    securityadmin

    Administratorzy zabezpieczeń

    serveradmin

    Administratorzy serwera

    setupadmin

    Administratorzy instalacji

    processadmin

    Administratorzy procesu

    diskadmin

    Administratorzy dysku

    dbcreator

    Twórcy bazy danych

    bulkadmin

    Można wykonać instrukcje BULK INSERT

Wartości kodów powrotnych

0 (sukces) lub 1 (brak)

Zestawy wyników

Nazwa kolumna

Typ danych

Description

ServerRole

sysname

Nazwa stała rola serwera

Uprawnienia

sysname

Uprawnienia skojarzone z ServerRole

Remarks

Uprawnienia, na liście zawierają Transact-SQL instrukcje, które mogą być wykonywane, a inne specjalne czynności, które mogą być wykonywane przez członków stała rola serwera. Aby wyświetlić listę ról stałej serwera, wykonać sp_helpsrvrole.

The sysadmin stała rola serwera has the permissions of all the other fixed server roles.

Uprawnienia

Członkostwo w grupie wymaga publiczne roli.

Przykłady

Następująca kwerenda zwraca uprawnienia związane z sysadmin stała rola serwera.

EXEC sp_srvrolepermission 'sysadmin';
GO