Was this page helpful?
Your feedback about this content is important. Let us know what you think.
Additional feedback?
1500 characters remaining
Export (0) Print
Expand All
Collapse the table of content
Expand the table of content
Expand Minimize

sp_script_synctran_commands (Transact-SQL)

Applies To: SQL Server 2014, SQL Server 2016 Preview

Topic Status: Some information in this topic is preview and subject to change in future releases. Preview information describes new features or changes to existing features in Microsoft SQL Server 2016 Community Technology Preview 2 (CTP2).

Generates a script that contains the sp_addsynctrigger calls to be applied at Subscribers for updatable subscriptions. There is one sp_addsynctrigger call for each article in the publication. The generated script also contains the sp_addqueued_artinfo calls that create the MSsubsciption_articles table that is needed to process queued publications. This stored procedure is executed at the Publisher on the publication database.

Topic link icon Transact-SQL Syntax Conventions

sp_script_synctran_commands [@publication = ] 'publication'
    [ , [@article = ] 'article']

[ @publication = ] 'publication'

Is the name of the publication to be scripted. publication is sysname, with no default.

[ @article = ] 'article'

Is the name of the article to be scripted. article is sysname, with a default of all, which specifies all articles are scripted.

0 (success) or 1 (failure)

sp_script_synctran_commands returns a result set that consists of a single nvarchar(4000) column. The result set forms the complete scripts necessary to create both the sp_addsynctrigger and sp_addqueued_artinfo calls to be applied at Subscribers.

sp_script_synctran_commands is used in snapshot and transactional replication.

sp_addqueued_artinfo is used for queued updatable subscriptions.

Only members of the sysadmin fixed server role or db_owner fixed database role can execute sp_script_synctran_commands.

Was this page helpful?
(1500 characters remaining)
Thank you for your feedback

Community Additions

© 2015 Microsoft