Skip to content

Expand wait_time_percent_of_uptime to accomodate >1,000% waits#585

Merged
erikdarlingdata merged 1 commit intoerikdarlingdata:devfrom
ChrisMayIVCE:dev
Apr 24, 2025
Merged

Expand wait_time_percent_of_uptime to accomodate >1,000% waits#585
erikdarlingdata merged 1 commit intoerikdarlingdata:devfrom
ChrisMayIVCE:dev

Conversation

@ChrisMayIVCE
Copy link

Hi Erik, love the new proc but I am getting some arithmetic errors in the block starting on line 1928 (the update on #wait_stats). This is ultimately due to having >1000% wait times as a percentage of server uptime:
image

I am not sure if this is a bug in the DMVs or accurate reporting, but this is from an Azure SQL Managed Instance being utilised as a data warehouse and this fix resolved the issue and now they appear as priority 20 results.

Can adjust how this is done if you would prefer, please let me know your thoughts

@erikdarlingdata erikdarlingdata added bug Something isn't working sp_PerfCheck High level performance checks for SQL Server labels Apr 24, 2025
@erikdarlingdata
Copy link
Owner

@ChrisMayIVCE You can totally have wait stats that are higher than uptime. It happens a lot particularly on servers where there's a lot of parallelism. Multiple cores emitting waits simultaneously can really add up. This is a pretty minimal change so I'm happy to push it on through. Thanks for the assist here!

@erikdarlingdata erikdarlingdata merged commit 6cf060a into erikdarlingdata:dev Apr 24, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working sp_PerfCheck High level performance checks for SQL Server

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants