alter subscription

Moves a subscription between replicate connections of the same replicate database that use the same Replication Server, without the need to rematerialize. The subscription may be for a database replication definition, table replication definition, function replication definition, or publication.

Syntax

alter subscription sub_name
     for {table_repdef | func_repdef | {publication pub | database replication definition db_repdef}
     with primary at pri_dataserver.pri_database
     move replicate from data_server1.database1 to data_server2.database2

Parameters

Examples

Usage

  • Use alter subscription to move subscriptions between replicate connections if you have created one or more alternate replicate connections. See Replication Server Administration Guide Volume 2 > Performance Tuning > Multi-Path Replication > Moving Subscriptions Between Connections.
  • Execute alter subscription at the Replication Server of the database where the replicated data will be stored.

  • See the Replication Server Administration Guide Volume 1 for more information about subscriptions and the role they play in replication.

  • You cannot use alter subscription if the primary Replication Server version is earlier than 1570. Instead, you must drop and re-create the subscription at the connection you want.

  • To move multiple subscriptions that must replicate through the same path, suspend log transfer for the primary connections and then resume log transfer after you move all the subscriptions.

Permissions

To execute create subscription, you must have the following login names and permissions:
  • The same login name and password at the replicate Replication Server, primary Replication Server, and primary Adaptive Server database.

  • “create object” or “sa” permission at the replicate Replication Server where you enter this command.

  • “create object”, “primary subscribe”, or “sa” permission at the primary Replication Server.

  • select permission on the primary table in the primary Adaptive Server database.

  • execute permission on the rs_marker stored procedure in the primary Adaptive Server database.

  • The replicate database maintenance user must have select, insert, update, and delete permissions on the replicate table, and execute permissions for functions used in replication.

Related reference
create alternate connection
create subscription