Sets the configuration and security information used by synchronization triggers of immediate updating Subscribers when connecting to the Publisher.
sp_link_publication [@publisher =] 'publisher',
[@publisher_db =] 'publisher_db', [@publication =] 'publication',
[@security_mode =] security_mode [,[@login =] 'login']
[,[@password =] 'password']
0 (success) or 1 (failure)
sp_link_publication is used by immediate updating Subscribers in snapshot and transactional replication.
sp_link_publication can be used for both push and pull subscriptions. It can be called before or after the subscription is created. An entry is inserted or updated in the MSsubscription_properties system table. Use sp_helpsubscription_properties to view the values (publisher_security_mode, publisher_login, publisher_password) being set.
For push subscriptions, the entry can be cleaned up by sp_subscription_cleanup. For pull subscriptions, the entry can be cleaned up by sp_droppullsubscription or sp_subscription_cleanup. You can also call sp_link_publisher with a NULL password to clear the entry in the MSsubscription_properties system table for security concerns.
Only members of the sysadmin fixed server role can execute sp_link_publication.
sp_droppullsubscription | sp_subscription_cleanup |
sp_helpsubscription_properties | System Stored Procedures |