FIX: Stored procedures don't generate on a subscription database when you configure a transactional replication in SQL Server 2012

Article ID: 2863979 - View products that this article applies to.
Expand all | Collapse all

On This Page

Symptoms

Consider the following scenario:
  • You configure a transactional replication on a computer that is running Microsoft SQL Server 2012.
  • You call the sp_addpublication stored procedure by setting the allow_initialize_from_backup property to N'true'. This adds a publication on the publisher.
  • You call the sp_addarticle stored procedureby setting the property type to N'proc schema only'. This adds a schema-only stored procedure article on the publisher.
  • You call the sp_addarticle stored procedure to add a table article. This replicates a table named "table1" on the publisher.
In this scenario, the sp_MSdel_table1, sp_MSins_table1, and sp_MSupd_table1 stored procedures are not generated on the subscription database.

Note This issue does not occur if you do not add the schema-only stored procedure article.

Resolution

Cumulative update information

Cumulative update 5 for SQL Server 2012 Service Pack 1

The fix for this issue was first released in Cumulative Update 5. For more information about how to obtain this cumulative update package for SQL Server 2012 Service Pack 1, click the following article number to view the article in the Microsoft Knowledge Base:
2861107 Cumulative update package 5 for SQL Server 2012 Service Pack 1
Note Because the builds are cumulative, each new fix release contains all the hotfixes and all the security fixes that were included with the previous SQL Server 2012 Service Pack 1 fix release. We recommend that you consider applying the most recent fix release that contains this hotfix. For more information, click the following article number to view the article in the Microsoft Knowledge Base:
2772858 The SQL Server 2012 builds that were released after SQL Server 2012 Service Pack 1 was released

Status

Microsoft has confirmed that this is a problem in the Microsoft products that are listed in the "Applies to" section.

Workaround

To work around this issue, perform the following actions:
  • Set the allow_initialize_from_backup property to N'false' when you execute sp_addpublication.
  • Add the table article to the publisher.
  • Execute the sp_changepublication stored procedure by setting the allow_initialize_from_backup property to true. For example, the stored procedure is as follows:
    exec sp_changepublication
    @publication    = N'$(PublicationName)',
    @property         = N'allow_initialize_from_backup',
    @value             = N'true'

Properties

Article ID: 2863979 - Last Review: July 15, 2013 - Revision: 1.1
Applies to
  • Microsoft SQL Server 2012 Service Pack 1, when used with:
    • Microsoft SQL Server 2012 Standard
    • Microsoft SQL Server 2012 Developer
    • Microsoft SQL Server 2012 Enterprise
Keywords: 
kbqfe kbfix kbsurveynew kbexpertiseadvanced KB2863979

Give Feedback

 

Contact us for more help

Contact us for more help
Connect with Answer Desk for expert help.
Get more support from smallbusiness.support.microsoft.com