You have a SQL Managed Instance that hosts a critical OLTP database. You notice that the average query wait time has increased significantly over the past hour. You need to identify the top resource waits. What should you use?
sys.dm_os_wait_stats aggregates cumulative wait statistics by wait type across the instance, letting you rank the top resource waits causing the slowdown. It directly satisfies the need to identify which resource the OLTP workload is waiting on.
Why this answer
C is correct because sys.dm_os_wait_stats is the dynamic management view that aggregates wait statistics across all sessions in the SQL Server instance, including SQL Managed Instance. It provides cumulative wait times categorized by wait type (e.g., PAGEIOLATCH, LCK_M_S), making it the appropriate tool to identify top resource waits when average query wait time increases.
Exam trap
The trap here is that candidates confuse performance metrics DMVs (like sys.dm_exec_query_stats) with wait statistics DMVs, or they assume Query Store Wait Stats is the primary diagnostic tool for real-time wait analysis, when sys.dm_os_wait_stats is the direct and authoritative source for identifying top resource waits.
How to eliminate wrong answers
Option A is wrong because sys.dm_exec_query_stats returns aggregated performance statistics for cached query plans (e.g., CPU time, logical reads), not wait statistics; it cannot show resource waits. Option B is wrong because Query Store Wait Stats in SSMS is a feature that surfaces wait statistics from the Query Store, but it relies on the Query Store being enabled and configured, and it does not provide the comprehensive, instance-level wait statistics that sys.dm_os_wait_stats does for immediate diagnosis. Option D is wrong because sys.dm_db_index_usage_stats tracks index usage patterns (seeks, scans, updates), not wait times or resource contention.