Skip to content

Commit 1f5cf04

Browse files
authored
Update sp_Blitz.sql
1 parent a0ff597 commit 1f5cf04

File tree

1 file changed

+4
-4
lines changed

1 file changed

+4
-4
lines changed

sp_Blitz.sql

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -6778,7 +6778,7 @@ IF @ProductVersionMajor >= 10
67786778

67796779
IF @Debug IN (1, 2) RAISERROR('Running CheckId [%d].', 0, 1, 99) WITH NOWAIT;
67806780

6781-
EXEC dbo.sp_MSforeachdb 'USE [?]; SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED; IF EXISTS (SELECT * FROM sys.tables WITH (NOLOCK) WHERE name = ''sysmergepublications'' ) IF EXISTS ( SELECT * FROM sysmergepublications WITH (NOLOCK) WHERE retention = 0) INSERT INTO #BlitzResults (CheckID, DatabaseName, Priority, FindingsGroup, Finding, URL, Details) SELECT DISTINCT 99, DB_NAME(), 110, ''Performance'', ''Infinite merge replication metadata retention period'', ''https://www.brentozar.com/go/merge'', (''The ['' + DB_NAME() + ''] database has merge replication metadata retention period set to infinite - this can be the case of significant performance issues.'')';
6781+
EXEC dbo.sp_MSforeachdb 'USE [?]; SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED; IF EXISTS (SELECT * FROM sys.tables WITH (NOLOCK) WHERE name = ''sysmergepublications'' ) IF EXISTS ( SELECT * FROM sysmergepublications WITH (NOLOCK) WHERE retention = 0) INSERT INTO #BlitzResults (CheckID, DatabaseName, Priority, FindingsGroup, Finding, URL, Details) SELECT DISTINCT 99, DB_NAME(), 110, ''Performance'', ''Infinite merge replication metadata retention period'', ''https://www.brentozar.com/go/merge'', (''The ['' + DB_NAME() + ''] database has merge replication metadata retention period set to infinite - this can be the case of significant performance issues.'')';
67826782
END;
67836783
/*
67846784
Note that by using sp_MSforeachdb, we're running the query in all
@@ -7044,10 +7044,10 @@ IF @ProductVersionMajor >= 10
70447044
''https://www.brentozar.com/go/manylogs'',
70457045
(''The ['' + DB_NAME() + ''] database has multiple log files on the '' + LEFT(physical_name, 1) + '' drive. This is not a performance booster because log file access is sequential, not parallel.'')
70467046
FROM [?].sys.database_files WHERE type_desc = ''LOG''
7047-
AND ''?'' NOT IN (''rdsadmin'',''tempdb'')
7047+
AND ''?'' NOT IN (''rdsadmin'',''tempdb'')
70487048
GROUP BY LEFT(physical_name, 1)
7049-
HAVING COUNT(*) > 1
7050-
AND SUM(size) < 268435456 OPTION (RECOMPILE);';
7049+
HAVING COUNT(*) > 1
7050+
AND SUM(size) < 268435456 OPTION (RECOMPILE);';
70517051
END;
70527052

70537053
IF NOT EXISTS ( SELECT 1

0 commit comments

Comments
 (0)