Skip to content

Commit 491e8b0

Browse files
committed
BrentOzarULTD#1311 sp_BlitzIndex add ALTER TABLE REBUILD command for heaps
For forwarded fetches warning. Closes BrentOzarULTD#1311.
1 parent 6e1398f commit 491e8b0

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

sp_BlitzIndex.sql

+1-1
Original file line numberDiff line numberDiff line change
@@ -1752,7 +1752,7 @@ SELECT
17521752
THEN N'--DROP INDEX ' + QUOTENAME([index_name]) + N' ON '
17531753
+ QUOTENAME([schema_name]) + N'.' + QUOTENAME([object_name])
17541754
ELSE
1755-
CASE index_id WHEN 0 THEN N'--I''m a Heap!'
1755+
CASE index_id WHEN 0 THEN N'ALTER TABLE ' + QUOTENAME([database_name]) + N'.' + QUOTENAME([schema_name]) + N'.' + QUOTENAME([object_name]) + ' REBUILD;'
17561756
ELSE
17571757
CASE WHEN is_XML = 1 OR is_spatial=1 THEN N'' /* Not even trying for these just yet...*/
17581758
ELSE

0 commit comments

Comments
 (0)