Adding an Article to a Publication
As you create a publication, you add articles to be published. You can add articles from within the Publication Wizard or by using the sp_addmergearticle stored procedure.
Using the Publication Wizard to Add an Article
When you use the Publication Wizard to create a publication, you select the articles you want to publish by selecting the check box next to each article. Because you have previously indicated in the Publication Wizard that this publication will have Microsoft SQL Server 2005 Compact Edition (SQL Server Compact Edition) Subscribers, the Publication Wizard will configure the articles appropriately. For more information about articles, see the "Article Options for Merge Replication" topic in SQL Server 2005 Books Online.
Using sp_addmergearticle to Add an Article
The sp_addmergearticle stored procedure lets you add an article to a publication. This stored procedure has many arguments. One of the arguments, @compensate\_for\_errors, is modified in SQL Server Compact Edition. SQL Server Compact Edition supports both @compensate\_for\_errors=false and @compensate\_for\_errors=true, while SQL Server CE only supported @compensate\_for\_errors=true. If your publication is set to @compensate\_for\_errors=false, you will receive errors on the subscriber until the problematic row is changed.
The following table lists arguments that either require a specific value or are ignored when you use SQL Server Compact Edition Subscribers.
Argument | Description or Requirement | SQL Server version |
---|---|---|
@pre_creation_cmd |
Only 'drop' is supported. |
Both |
@creation_script |
Ignored by SQL Server Compact Edition |
Both |
@allow_interactive_resolver |
Ignored by SQL Server Compact Edition |
Both |
@logical_record_level_conflict_detection |
Only 'false' is supported. |
SQL Server 2005 only |
@logical_record_level_conflict_resolution |
Only 'false' is supported. |
SQL Server 2005 only |
Note
SQL Server Compact Edition does not support synchronizing with publications that contain logical records. Therefore, the parameters related to logical record level conflicts must be set to 'false'.
See Also
Concepts
Creating the Publication
Adding a Filter to an Article
Using Row-Level and Column-Level Tracking