How to check if PSP Optimization is enabled

There are many sites that show how to enable or disable PSPO, or PSP Optimization in SQL Server, however, not many describe how to see if it is currently enabled or disabled.

Here is a query that checks for this:

select *
from sys.database_scoped_configurations
where name = 'PARAMETER_SENSITIVE_PLAN_OPTIMIZATION'

If the value is 0, then PSP Optimization is disabled. If the value is 1, then it is enabled.

This entry was posted in Uncategorized. Bookmark the permalink.

Leave a comment