5. Select Customer from the list of Available Tables. Click Add.
6. On the SUBSCRIBE BY Restrictions tab, select the Customer table and
enterthe expression rep_key.
7. Click Finish to create the publication.
Adda subscr iption Eachuser ID that is to receive changes to a publication must have a
subscriptionto that publication. Subscriptionscan only be created for a
validremote user. You need to add a subscription to the SalesRepData
publicationfor the remote database user field_user.
Toadd a subscription
1. Open the Publications folder and select the SalesRepData publication in
theleft pane.
2. Click the SQL Remote Subscriptions tab in the right pane.
3. From the File menu, choose New SQL Remote Subscription.
TheSQL Remote Subscription Creation wizard appears.
4. Chooseto subscribe field_user. Entera Subscription value of rep1 and
clickFinish.
Thesubscription value is an expression that matches the Subscribe By
expressionin the publication. Ina later step, the field_user user ID is
assigneda rep_key value of rep1.
Youhave now set up the consolidated database.
Set up the remote database in Sybase Central
Theremote database needs to be created and configured in order to send and
receivemessages and participate in a SQL Remote setup.
Likethe consolidated database, the remote database needs a publisher (in
thiscase, the field_user user ID) to identify the source of outgoing
messages,and it needs to have hq_user identified as a user with
consolidatedpermissions. Itneeds the SalesRepData publication to be
createdand needs a subscription created for the hq_user user ID.
Theremote database also needs to be synchronized with the consolidated
database;that is, it needs to have a current copy of the data in order for the
replicationto start. Inthis case, there is no data in the publication as yet.
Thedatabase extraction utility enables you to carry out all the steps needed
tocreate a remote database complete with subscriptions and required user
IDs.
38