Aracılığıyla paylaş


ServerRole.AddMember Method

Adds a login to the fixed server role membership.

Namespace:  Microsoft.SqlServer.Management.Smo
Assembly:  Microsoft.SqlServer.Smo (in Microsoft.SqlServer.Smo.dll)

Syntax

'Bildirim
Public Sub AddMember ( _
    memberName As String _
)
'Kullanım
Dim instance As ServerRole
Dim memberName As String

instance.AddMember(memberName)
public void AddMember(
    string memberName
)
public:
void AddMember(
    String^ memberName
)
member AddMember : 
        memberName:string -> unit 
public function AddMember(
    memberName : String
)

Parameters

  • memberName
    Type: System.String
    A String value that specifies the login that is to be added to the fixed server role membership.

Examples

Managing Users, Roles, and Logins

See Also

Reference

ServerRole Class

Microsoft.SqlServer.Management.Smo Namespace

Other Resources

Permissions of Fixed Server Roles (Database Engine)

sp_addsrvrolemember (Transact-SQL)