A subscription instructs Replication Server to copy data from the primary table to the specified RepConnector connection. The subscription describes the replicated information that RepConnector can accept.
The following procedure describes how to create and then validate a subscription. You must verify that the subscription is valid both at the primary table and at the RepConnector connection.
Creating and validating the subscription at Replication
Server
Create the subscription using the RepConnector connection name as the parameter value for the with replicate at command. This is the name of the connection you created in the previous section.
All values in the following procedure refer to the worksheet entries in Appendix A, “Configuration Worksheets.”
Gather the following and record it on your worksheet where appropriate:
Name of the RepConnector connection (3.a) you created in “Creating the connection to RepConnector”
Name of the replication definition
Create the database subscription using the create subscription command:
create subscription <subscription_name> for <replication_definition_name> with replicate at <dataserver>.<database> without materialization
where:
subscription_name is the name of your subscription.
replication_definition_name is the name of the replication definition.
dataserver is the name of the database connection you created to connect to RepConnector.
database is the name of the database to which you are replicating. However, RepConnector does not use the database name; the database name here is a placeholder to meet Replication Server syntax requirements.
Because a RepConnector connection is the destination instead of an actual database, Sybase recommends you use a name that is unique and that represents the RepConnector connection.
For example:
create subscription authors_sub for authors_rep with replicate at RepConnector.RepCondb without materialization
Use the check subscription command to verify that the subscription is valid at the primary database and at the replicate database:
check subscription <subscription_name> for <replication_definition_name> with replicate at <dataserver>.<database>
where:
subscription_name is the name of the subscription.
replication_definition_name is the name of the table or function replication definition the subscription is for.
dataserver is the name of the RepConnector connection (3a).
database is the name of the database to which you are replicating. RepConnector does not use the database name and this is a placeholder to meet Replication Server syntax requirements.
For example:
check subscription authors_sub for authors_rep with replicate at RepConnector.RepCondb