Поделиться через


Свойство ServerConnection.FixedServerRoles

Возвращает предопределенную роль сервера, связанную с указанным соединением.

Пространство имен:  Microsoft.SqlServer.Management.Common
Сборка:  Microsoft.SqlServer.ConnectionInfo (в Microsoft.SqlServer.ConnectionInfo.dll)

Синтаксис

'Декларация
Public ReadOnly Property FixedServerRoles As FixedServerRoles 
    Get
'Применение
Dim instance As ServerConnection 
Dim value As FixedServerRoles 

value = instance.FixedServerRoles
public FixedServerRoles FixedServerRoles { get; }
public:
property FixedServerRoles FixedServerRoles {
    FixedServerRoles get ();
}
member FixedServerRoles : FixedServerRoles
function get FixedServerRoles () : FixedServerRoles

Значение свойства

Тип: Microsoft.SqlServer.Management.Common.FixedServerRoles
Значение объекта FixedServerRoles, указывающее предопределенную роль сервера, связанную с указанным по ссылке соединением.

Примеры

C#

ServerConnection conn = new ServerConnection();
Console.WriteLine(conn.FixedServerRoles.ToString());

PowerShell

$conn = new-object Microsoft.SqlServer.Management.Common.ServerConnection
Write-Host $conn.FixedServerRoles

См. также

Справочник

ServerConnection Класс

Пространство имен Microsoft.SqlServer.Management.Common

Другие ресурсы

Permissions of Fixed Server Roles