BrentOzarULTD / SQL-Server-First-Responder-Kit

sp_Blitz, sp_BlitzCache, sp_BlitzFirst, sp_BlitzIndex, and other SQL Server scripts for health checks and performance tuning.
http://FirstResponderKit.org
Other
3.37k stars 997 forks source link

sp_BlitzIndex has dependency on depricated procedure sp_BlitzInMemoryOLTP #3528

Closed netsec4u closed 5 months ago

netsec4u commented 5 months ago

Version of the script Version: 8.20 VersionDate: 20240522

What is the current behavior? If the script Install-All-Scripts.sql is used to install to a new database, the procedure sp_BlitzInMemoryOLTP is not created. The procedure sp_BlitzIndex output will reference sp_BlitzInMemoryOLTP in the "More Info" column when an in-memory index is returned in the output. Executing the statement in this column will fail with the error "Could not find stored procedure 'dbo.sp_BlitzInMemoryOLTP'."

If the current behavior is a bug, please provide the steps to reproduce. Create a new database and use Install-All-Scripts.sql to create procedures. Next execute sp_BlitzIndex against a database that contains an in-memory index with parameter Mode set to 4.

What is the expected behavior? With the deprecation of sp_BlitzInMemoryOLTP, the output of sp_BlitzIndex should not reference the deprecated procedure in the column "More Info". This column could be set to an empty string like the "Create TSQL" column, or display a message. This message could be conditional based on if the deprecated procedures not existing, otherwise it would display the current output.

Which versions of SQL Server and which OS are affected by this issue? Did this work in previous versions of our procedures? Issue duplicated with SQL Server 2017, but I expect this to be an issue for all versions of SQL Server that supports in-memory indexes. Previous versions that the Install-All-Scripts.sql script creates the procedure sp_BlitzInMemoryOLTP will not have this issue.

A work around would be to execute the script sp_BlitzInMemoryOLTP.sql to create the deprecated procedure, which is still included within the First Responder Kit.

BrentOzar commented 5 months ago

You're still welcome to use sp_BlitzInMemoryOLTP. It's in the deprecated folder. Cheers!