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
* Create sp_predindex.sql
* alpha version of sp_estindex
* fix linting error
* more md linting fixes
* Update sp_estindex.md
* mvp version
* add extended properties
* use label for repeatable code block
* update docs
* Update sp_estindex.md
* Update sp_estindex.md
* add sp_estindex
* alphabetize scripts
* CI produced files
* update .gitattributes
* encode file to utf8
* unit test stub
* CI produced files
* fix index drop for < 2016 sql
* CI produced files
* remove drop if
* CI produced files
* actually remove if
* CI produced files
* fix tsqllint errors
* CI produced files
* force build error for lint error
* build tests for sp_estindex
* add verbose mode test
* increase test cov for sp_estindex to 100%
* Update sp_estindex_tests.sql
* formatting
* CI produced files
* @verbose documentation
* remove spt usage for azure compatibility
* improve linting, readability, general quality of unit tests
* CI produced files
* add @verbose to documentation
* CI produced files
Co-authored-by: John McCall <[email protected]>
Co-authored-by: Appveyor <[email protected]>
SET @Msg ='No database provided, assuming current database.';
138
-
RAISERROR(@Msg, 10, 1) WITH NOWAIT;
144
+
IF (@Verbose =1)
145
+
BEGIN;
146
+
SET @Msg ='No database provided, assuming current database.';
147
+
RAISERROR(@Msg, 10, 1) WITH NOWAIT;
148
+
END;
139
149
END
140
150
ELSE IF (DB_ID(@DatabaseName) IS NULL)
141
151
BEGIN;
@@ -1175,6 +1185,10 @@ GO
1175
1185
1176
1186
EXEC sys.sp_addextendedproperty @name=N'@Emojis', @value=N'Use emojis when generating documentation. Default is 0.' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'PROCEDURE',@level1name=N'sp_doc';
1177
1187
GO
1188
+
1189
+
EXEC sys.sp_addextendedproperty @name=N'@Verbose', @value=N'Whether or not to print additional information during the script run. Default is 0.' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'PROCEDURE',@level1name=N'sp_doc';
1190
+
GO
1191
+
1178
1192
SET ANSI_NULLS ON;
1179
1193
GO
1180
1194
@@ -1505,6 +1519,12 @@ BEGIN TRY
1505
1519
WHERE COALESCE([equality_columns] +', ', '') + [inequality_columns] = @QuotedKeyColumns
1506
1520
AND ([included_columns] = @QuotedInclColumns OR [included_columns] IS NULL);
1507
1521
1522
+
IF (SELECTCOUNT(*) FROM##TempMissingIndex) = 0 AND (@Verbose = 1)
1523
+
BEGIN;
1524
+
SET @Msg ='No matching missing index statistics found.';
SET @Msg ='No database provided, assuming current database.';
138
-
RAISERROR(@Msg, 10, 1) WITH NOWAIT;
144
+
IF (@Verbose =1)
145
+
BEGIN;
146
+
SET @Msg ='No database provided, assuming current database.';
147
+
RAISERROR(@Msg, 10, 1) WITH NOWAIT;
148
+
END;
139
149
END
140
150
ELSE IF (DB_ID(@DatabaseName) IS NULL)
141
151
BEGIN;
@@ -1175,3 +1185,7 @@ GO
1175
1185
1176
1186
EXEC sys.sp_addextendedproperty @name=N'@Emojis', @value=N'Use emojis when generating documentation. Default is 0.' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'PROCEDURE',@level1name=N'sp_doc';
1177
1187
GO
1188
+
1189
+
EXEC sys.sp_addextendedproperty @name=N'@Verbose', @value=N'Whether or not to print additional information during the script run. Default is 0.' , @level0type=N'SCHEMA',@level0name=N'dbo', @level1type=N'PROCEDURE',@level1name=N'sp_doc';
0 commit comments