Learn how to use RCL commands to prepare a publication for subscription and create a subscription against it.
The replication definition specifies the source and destination tables or stored procedure and the columns or parameters that are sent to the subscribing database.
Publication information is stored in the rs_publications system table in the source Replication Server RSSD. It includes the name of the publication, data server, and database. The publication name must be unique for the source Replication Server and database.
create publication pubs2_pub with primary at TOKYO_DS.pubs2
Publication information is not copied to the destination Replication Server until you create a subscription against the publication at the destination Replication Server.
See Replication Server Reference Manual > Replication Server Commands for complete syntax and usage guidelines.
Each article specifies the publication to which it belongs and the table or function replication definition with which it identifies. A publication can contain articles based on the same or different replication definitions. The replication definition and publication must exist when you create the article.
An article includes the names of the publication, the replication definition, and the source data server and database. Article information is stored in the rs_articles and rs_whereclauses system tables. Each article name must be unique within the publication.
create article titles_art for pubs2_pub with primary at TOKYO_DS.pubs2 with replication definition titles_rep
An article can include where clauses that specify the rows or parameters to be sent to subscribing databases.
Creating an article invalidates the publication, which makes it ineligible for subscription. After you create an article, you must change the status of the publication to VALID, using validate publication, before you can create subscriptions against it.
See Replication Server Reference Manual > Replication Server Commands for complete syntax and usage guidelines.
When you validate a publication, Replication Server checks that the publication contains at least one article and marks the publication ready for subscription.
Whenever you add or drop an article from a publication, Replication Server invalidates the publication. To mark the publication VALID—and ready for subscription—you must execute validate publication.
After you validate a publication, you can create a publication subscription against it.
validate publication pubs2_pub with primary at TOKYO_DS.pubs2
See Replication Server Reference Manual > Replication Server Commands for complete syntax and usage guidelines.