Sets a replication database option for the specified database. This stored procedure is executed at the Publisher or Subscriber on any database.
sp_replicationdboption is used in snapshot replication, transactional replication, and merge replication.
This procedure creates or drops specific replication system tables, security accounts, and so on, depending on the options given. Sets the corresponding category bit in the master.sysdatabases system table and creates the necessary system tables.
To disable publishing, the publication database must be online. If a database snapshot exists for the publication database, it must be dropped before disabling publishing. A database snapshot is a read-only offline copy of a database, and is not related to a replication snapshot. For more information, see Database Snapshots.