sp_replcounters Replication Stored Procedure

Returns replication statistics about latency, throughput, and transaction count for each published database. Used by SQL Performance Monitor.

Syntax

sp_replcounters

Remarks

This stored procedure returns a list of published databases, and for each published database, returns the number of replicated transactions in the log that have not yet been delivered to the distribution database. It also returns the number of transactions per second that have been read out of the log.

This information can be viewed by using the appropriate counters in SQL Performance Monitor.

Example

This example shows information about replicated transactions in the pubs database.

sp_replcounters
go
database  repl. trans  repl. rate trans/sec  repl. latency(sec)
--------  -----------  --------------------  ------------------
pubs      72           0.739645              174015000.0

Permission

Execute permission defaults to the system administrator and is granted to probe.

Table Used

None.

See Also

sp_replcmds sp_replflush
sp_repldone sp_replstatus