You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
@regression_comparator varchar(20) = NULL, /*what difference to use ('relative' or 'absolute') when comparing @sort_order's metric for the normal time period with the regression time period.*/
30382
30382
@regression_direction varchar(20) = NULL, /*when comparing against the regression baseline, want do you want the results sorted by ('magnitude', 'improved', or 'regressed')?*/
30383
30383
@include_query_hash_totals bit = 0, /*will add an additional column to final output with total resource usage by query hash, may be skewed by query_hash and query_plan_hash bugs with forced plans/plan guides*/
30384
+
@include_maintenance bit = 0, /*Set this bit to 1 to add maintenance operations such as index creation to the result set*/
30384
30385
@help bit = 0, /*return available parameter details, etc.*/
30385
30386
@debug bit = 0, /*prints dynamic sql, statement length, parameter and variable values, and raw temp table contents*/
30386
30387
@troubleshoot_performance bit = 0, /*set statistics xml on for queries against views*/
@@ -30496,6 +30497,7 @@ BEGIN
30496
30497
WHEN N'@regression_comparator' THEN 'what difference to use (''relative'' or ''absolute'') when comparing @sort_order''s metric for the normal time period with any regression time period.'
30497
30498
WHEN N'@regression_direction' THEN 'when comparing against any regression baseline, what do you want the results sorted by (''magnitude'', ''improved'', or ''regressed'')?'
30498
30499
WHEN N'@include_query_hash_totals' THEN N'will add an additional column to final output with total resource usage by query hash, may be skewed by query_hash and query_plan_hash bugs with forced plans/plan guides'
30500
+
WHEN N'@include_maintenance' THEN N'Set this bit to 1 to add maintenance operations such as index creation to the result set'
30499
30501
WHEN N'@help' THEN 'how you got here'
30500
30502
WHEN N'@debug' THEN 'prints dynamic sql, statement length, parameter and variable values, and raw temp table contents'
30501
30503
WHEN N'@troubleshoot_performance' THEN 'set statistics xml on for queries against views'
@@ -30551,6 +30553,7 @@ BEGIN
30551
30553
WHEN N'@regression_comparator' THEN 'relative, absolute'
30552
30554
WHEN N'@regression_direction' THEN 'regressed, worse, improved, better, magnitude, absolute, whatever'
30553
30555
WHEN N'@include_query_hash_totals' THEN N'0 or 1'
30556
+
WHEN N'@include_maintenance' THEN N'0 or 1'
30554
30557
WHEN N'@help' THEN '0 or 1'
30555
30558
WHEN N'@debug' THEN '0 or 1'
30556
30559
WHEN N'@troubleshoot_performance' THEN '0 or 1'
@@ -30606,6 +30609,7 @@ BEGIN
30606
30609
WHEN N'@regression_comparator' THEN 'NULL; absolute if @regression_baseline_start_date is specified'
30607
30610
WHEN N'@regression_direction' THEN 'NULL; regressed if @regression_baseline_start_date is specified'
30608
30611
WHEN N'@include_query_hash_totals' THEN N'0'
30612
+
WHEN N'@include_maintenance' THEN N'0'
30609
30613
WHEN N'@help' THEN '0'
30610
30614
WHEN N'@debug' THEN '0'
30611
30615
WHEN N'@troubleshoot_performance' THEN '0'
@@ -31063,7 +31067,7 @@ Hold plan_ids for matching wait filter
31063
31067
CREATE TABLE
31064
31068
#wait_filter
31065
31069
(
31066
-
plan_id bigint PRIMARY KEY
31070
+
plan_id bigint PRIMARY KEY CLUSTERED
31067
31071
);
31068
31072
31069
31073
/*
@@ -31557,19 +31561,19 @@ CREATE TABLE
31557
31561
CREATE TABLE
31558
31562
#include_databases
31559
31563
(
31560
-
database_name sysname PRIMARY KEY
31564
+
database_name sysname PRIMARY KEY CLUSTERED
31561
31565
);
31562
31566
31563
31567
CREATE TABLE
31564
31568
#exclude_databases
31565
31569
(
31566
-
database_name sysname PRIMARY KEY
31570
+
database_name sysname PRIMARY KEY CLUSTERED
31567
31571
);
31568
31572
31569
31573
CREATE TABLE
31570
31574
#requested_but_skipped_databases
31571
31575
(
31572
-
database_name sysname PRIMARY KEY,
31576
+
database_name sysname PRIMARY KEY CLUSTERED,
31573
31577
reason varchar(100) NOT NULL
31574
31578
);
31575
31579
@@ -32997,6 +33001,8 @@ SELECT
32997
33001
ISNULL(@workdays, 0),
32998
33002
@include_query_hash_totals =
32999
33003
ISNULL(@include_query_hash_totals, 0),
33004
+
@include_maintenance =
33005
+
ISNULL(@include_maintenance, 0),
33000
33006
/*
33001
33007
doing start and end date last because they're more complicated
33002
33008
if start or end date is null,
@@ -35426,7 +35432,8 @@ END;
35426
35432
/*
35427
35433
This section screens out index create and alter statements because who cares
0 commit comments