Export (0) Print
Expand All
Expand Minimize
This topic has not yet been rated - Rate this topic

sp_mergemetadataretentioncleanup

SQL Server 2000

  New Information - SQL Server 2000 SP3.

Requires Service Pack 1 or later. Performs a manual cleanup of meta data in the MSmerge_genhistory, MSmerge_contents and MSmerge_tombstone system tables. This stored procedure is executed at each Publisher and Subscriber in the topology.

Syntax

sp_mergemetadataretentioncleanup

Return Code Values

0 (success) or 1 (failure)

Remarks

sp_mergemetadataretentioncleanup requires SQL Server 2000 Service Pack 1 or later. See Merge Meta Data Cleanup in How Merge Replication Works for more information on meta data cleanup.

Important  If there are multiple publications on a database, and any one of those publications uses an infinite publication retention period (@retention=0), running sp_mergemetadataretentioncleanup will not clean up the merge replication change tracking meta data for the database. For this reason, use infinite publication retention with caution.

Permissions

Only members of the sysadmin fixed server role, the db_owner fixed database role, or the publication access list for at least one publication can execute sp_mergemetadataretentioncleanup.

See Also

How Merge Replication Works

MSmerge_genhistory

MSmerge_contents

MSmerge_tombstone

Did you find this helpful?
(1500 characters remaining)
Thank you for your feedback
Show:
© 2014 Microsoft. All rights reserved.