Skip to content

Commit e2dfb78

Browse files
committed
BrentOzarULTD#324 sp_Blitz removed % of waits in details
Probably the world’s worst fix, but this used windowing functions and ain’t nobody got time for that.
1 parent 1b82da3 commit e2dfb78

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sp_Blitz.sql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -5509,10 +5509,10 @@ IF @ProductVersionMajor >= 10 AND NOT EXISTS ( SELECT 1
55095509
,'http://BrentOzar.com/go/waits' AS URL
55105510
, Details = CAST(CAST(SUM(os.wait_time_ms / 1000.0 / 60 / 60) OVER (PARTITION BY os.wait_type) AS NUMERIC(18,1)) AS NVARCHAR(20)) + N' hours of waits, ' +
55115511
CAST(CAST((SUM(60.0 * os.wait_time_ms) OVER (PARTITION BY os.wait_type) ) / @MSSinceStartup AS NUMERIC(18,1)) AS NVARCHAR(20)) + N' minutes average wait time per hour, ' +
5512-
CAST(CAST(
5512+
/* CAST(CAST(
55135513
100.* SUM(os.wait_time_ms) OVER (PARTITION BY os.wait_type)
55145514
/ (1. * SUM(os.wait_time_ms) OVER () )
5515-
AS NUMERIC(18,1)) AS NVARCHAR(40)) + N'% of waits, ' +
5515+
AS NUMERIC(18,1)) AS NVARCHAR(40)) + N'% of waits, ' + */
55165516
CAST(CAST(
55175517
100. * SUM(os.signal_wait_time_ms) OVER (PARTITION BY os.wait_type)
55185518
/ (1. * SUM(os.wait_time_ms) OVER ())

0 commit comments

Comments
 (0)