Deleting publications and subscriptions

Before you can delete either a publication or a subscription, you must first delete all the articles in the publication or subscription.

Before you can delete a publication, you must first delete all subscriptions that subscribe to that publication.

NoteYou must suspend the database connection before you delete a publication or subscription. See “Suspending and resuming database connections” for more information.

To delete a publication, use sp_droppub:

sp_droppub pub_name

where pub_name is the name of the publication.

To delete a subscription, use sp_dropsub:

sp_dropsub sub_name

where sub_name is the name of the subscription.