O'Reilly logo

Guru's Guide to SQL Server Architecture and Internals, The by Ken Henderson

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

The sp_repldone Procedure

Once the Log Reader Agent finishes calling sp_replcmds and writing new entries to MSrepl_commands and MSrepl_transactions, it calls sp_repldone to indicate that the specified log records have been successfully replicated (to the distributor). This allows SQL Server to purge the log records as necessary. (Log records for transactional replication articles cannot be purged until the articles are successfully replicated to the distributor.)

Note that you shouldn't execute sp_repldone manually. Doing so can invalidate the order and consistency of replicated transactions. If you run into an emergency situation where your transaction log is overflowing because replicated transactions refuse to be purged (and you're certain ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required