When you query the latency of a transactional replication in Microsoft SQL Server 2008, in SQL Server 2008 R2, or in SQL Server 2012, the Distribution Agent returns an incorrect value.
For example, you run the following command to query the latency of a transactional replication:
The information in this table incorrectly reports that the latency is increasing. The incorrect latency value is displayed in the following locations:
For example, you run the following command to query the latency of a transactional replication:
select delivered_commands, current_delivery_latency, delivery_latency, time from distribution..msdistribution_history where agent_id=(select id from distribution..MSdistribution_agents where subscriber_db='<SubscriberDB>') order by time desc
However, you receive the following incorrect result:delivered_commands | current_delivery_latency | delivery_latency | Time |
118 | 1843 | 1833 | 2012-06-20 12:39:30.910 |
119 | 502086 | 251959 | 2012-06-20 12:38:50.890 |
119 | 201946 | 101889 | 2012-06-20 12:33:50.750 |
18 | 0 | 1823 | 2012-06-20 12:28:50.590 |
- The current_delivery_latency column in the msdistribution_history table in the distribution database
- The delivery_latency column in the msdistribution_history table in the distribution database
- The Distribution:Delivery Latency performance counter in Performance Monitor