Skip to main content

WAIT_ON_SYNC_STATISTICS_REFRESH

Short Description

You have set AUTO_UPDATE_STATISTICS and your query is being suspended whilst out of date stats are updated.

Detailed Description

Having object statistics up to date is key to the wellbeing of your database. SQL Server can manage the update of these statistics. The possible downside here is that if SQL Server decides the statistics are out of date on a table, it will suspend your query, refresh the statistics and then carry on. This can cause issues on large objects where the refresh of stats can take a significant time.

How to reduce this wait

Consider using the NO_WAIT option which will refresh the statistics asynchronously for your selected database.

SET AUTO_UPDATE_STATISTICS_ASYNC ON WITH NO_WAIT

SQL Server Documentation - AUTO_UPDATE_STATISTICS

SQL Authority blog - Resolve WAIT_ON_SYNC_STATISTICS_REFRESH Wait Type

Search online

If this article doesn't have the information you need you can try searching online. Remember, you can contribute suggestions to this page.

DBmarlin Trial