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
Expand Minimize


SQL Server 2000

Changes the properties of the distribution database. This stored procedure is executed at the Distributor on the distribution database.


sp_changedistributiondb [ @database = ] 'database'
[ , [ @property = ] 'property' ]
    [ , [ @value = ] 'value' ]


[@database =] 'database'

Is the name of the database. database is sysname, with no default.

[@property =] 'property'

Is the property to change for the given database. property is sysname, and can be one of these values.

Value Description
history_retention History table retention period.
max_distretention Maximum distribution retention period. This value must be greater than or equal to the retention period of all transactional publications in the distribution database.
min_distretention Minimum distribution retention period.
NULL (default) All available property values are printed.

[@value =] 'value'

Is the new value for the specified property. value is nvarchar(255), with a default of NULL.

Return Code Values

0 (success) or 1 (failure)


sp_changedistributiondb is used in all types of replication.


Only members of the sysadmin fixed server role can execute sp_changedistributiondb.

See Also




System Stored Procedures

© 2015 Microsoft