Skip to content

Commit 92794af

Browse files
committed
#2280 sp_BlitzIndex fixing inactive filter
Bug fix for #2280.
1 parent 6f3d7f9 commit 92794af

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

sp_BlitzIndex.sql

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1231,8 +1231,8 @@ BEGIN TRY
12311231
/* Heaps, clustered, nonclustered, XML, spatial, Cluster Columnstore, NC Columnstore */ ' +
12321232
CASE WHEN @TableName IS NOT NULL THEN N' and so.name=' + QUOTENAME(@TableName,N'''') + N' ' ELSE N'' END +
12331233
CASE WHEN ( @IncludeInactiveIndexes = 0
1234-
OR @Mode NOT IN (0, 4)
1235-
OR @TableName IS NOT NULL )
1234+
AND @Mode IN (0, 4)
1235+
AND @TableName IS NULL )
12361236
THEN N'AND ( us.user_seeks + us.user_scans + us.user_lookups + us.user_updates ) > 0'
12371237
ELSE N''
12381238
END

0 commit comments

Comments
 (0)