Removes metadata when a subscription is dropped at a Subscriber. For a normal subscription, the metadata includes an entry in the system table MSreplication_subscriptions. For a synchronizing transaction subscription, it also includes immediate-updating triggers.
sp_subscription_cleanup [@publisher =] 'publisher',
[@publisher_db =] 'publisher_db'
[,[@publication =] 'publication']
0 (success) or 1 (failure)
sp_subscription_cleanup is used in all types of replication.
Only members of the sysadmin fixed server role or the db_owner fixed database role can execute sp_subscription_cleanup.
sp_expired_subscription_cleanup | System Stored Procedures |
sp_mergesubscription_cleanup |