sp_msx_get_account (Transact-SQL)
TOC
Collapse the table of content
Expand the table of content

sp_msx_get_account (Transact-SQL)

 

Lists information on the credential that the target server uses to log in to the master server.

Applies to: SQL Server (SQL Server 2008 through current version).

Topic link icon Transact-SQL Syntax Conventions

  
sp_msx_get_account  

0 (success) or 1 (failure)

Returns the following result set:

Column NameTypeDescription
msx_connectionintMaster server connection number.
msx_credential_idintID of the credential used for this master server connection.
msx_credential_namesysnameName of the credential used for this master server connection.
msx_login_namenvarchar(4000)Domain name and user name of the Windows user for the credential.

Returns an empty result set if there is no credential specified for this target server. To set the credential, use sp_msx_set_account.

Requires membership in the sysadmin fixed server role.

The following example lists information for the credential that this target server uses to log in to the master server.

USE msdb ;  
GO  
  
EXECUTE dbo.sp_msx_get_account ;  
GO  

Here is a sample result set:

msx_connection msx_credential_id msx_credential_name msx_login_name

-------------- ----------------- -------------------- ------------------------------

1 65538 MsxAccount AdventureWorks2012\MsxAccount

SQL Server Agent Stored Procedures (Transact-SQL)
CREATE CREDENTIAL (Transact-SQL)
sp_msx_set_account (Transact-SQL)

Community Additions

ADD
Show:
© 2016 Microsoft