Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Collapse the table of content
Expand the table of content


SQL Server 2000

  New Information - SQL Server 2000 SP3.

Creates an entry in the sysservers table (if there is not one), marks the server entry as a Distributor, and stores property information. This stored procedure is executed at the Distributor on the master database to register and mark the server as a distributor. In the case of a remote distributor, it is also executed at the Publisher from the master database to register the remote distributor.


sp_adddistributor [ @distributor = ] 'distributor'
[ , [ @heartbeat_interval = ] heartbeat_interval ]
    [ , [ @password = ] 'password' ]
    [ , [ @from_scripting = ] from_scripting ]


[@distributor = ] 'distributor'

Is the distribution server name. distributor is sysname, with no default. This parameter is only used if setting up a remote Distributor. It adds entries for the Distributor properties in the msdb..MSdistributor table.

[@heartbeat_interval = ] heartbeat_interval

Is the maximum number of minutes that an agent can go without logging a progress message. heartbeat_interval is int, with a default of 10 minutes. A SQL Agent Job is created that wakes up on this interval to check the status of the replication agents that are running.

[@password = ] 'password']

Is the password of the distributor_admin login. password is sysname, with a default of NULL. If NULL or N, password is reset to a random value. The password must be configured when the first remote distributor that is not trusted is added. distributor_admin login and password are stored for linked server entry used for a distributor RPC connection, including local connections. If distributor is local, the password for distributor_admin is set to a new value.

Security Note  NULL passwords are not recommended.

[@from_scripting = ] from_scripting

For internal use only.

Return Code Values

0 (success) or 1 (failure)


sp_adddistributor is used in snapshot replication, transactional replication, and merge replication.


Only members of the sysadmin fixed server role can execute sp_adddistributor.

See Also




System Stored Procedures

© 2015 Microsoft