Skip to content

Latest commit

 

History

History
78 lines (55 loc) · 2.3 KB

sp-msx-enlist-transact-sql.md

File metadata and controls

78 lines (55 loc) · 2.3 KB
title description author ms.author ms.reviewer ms.date ms.service ms.subservice ms.topic f1_keywords helpviewer_keywords dev_langs
sp_msx_enlist (Transact-SQL)
sp_msx_enlist adds the current server to the list of available servers on the master server.
markingmyname
maghan
randolphwest
08/21/2024
sql
system-objects
reference
sp_msx_enlist_TSQL
sp_msx_enlist
sp_msx_enlist
TSQL

sp_msx_enlist (Transact-SQL)

[!INCLUDE SQL Server]

Adds the current server to the list of available servers on the master server.

Caution

The sp_msx_enlist stored procedure edits the registry. Manual editing of the registry isn't recommended, because inappropriate or incorrect changes can cause serious configuration problems for your system. Therefore, only experienced users should use the Registry Editor program to edit the registry. For more information, see the Microsoft Windows documentation.

:::image type="icon" source="../../includes/media/topic-link-icon.svg" border="false"::: Transact-SQL syntax conventions

Syntax

sp_msx_enlist
    [ @msx_server_name = ] N'msx_server_name'
    [ , [ @location = ] N'location' ]
[ ; ]

Arguments

[ @msx_server_name = ] N'msx_server_name'

The name of the multiserver administration (master) server. @msx_server_name is sysname, with no default.

[ @location = ] N'location'

The location of the target server to add. @location is nvarchar(100), with a default of NULL.

Return code values

0 (success) or 1 (failure).

Result set

None.

Permissions

Permissions to execute this procedure default to members of the sysadmin fixed server role.

Examples

The following example enlists the current server into the AdventureWorks1 master server. The location for the current server is Building 21, Room 309, Rack 5.

USE msdb;
GO

EXEC dbo.sp_msx_enlist N'AdventureWorks1',
    N'Building 21, Room 309, Rack 5';
GO

Related content