Skip to content

sp_QuickieStore: If Capturing Waits is Disabled on a 2017+ Box, our Warning Message Lies #575

@ReeceGoding

Description

@ReeceGoding

Version of the script
This came in somewhere around 5.2. It wasn't present in 5.1.

What is the current behavior?
If the capture of wait stats is disabled on a 2017+ box, we falsely claim that the product version can't capture it. For example, my shiny new 2022 container reports

The sort order (cpu waits) you chose is invalid in product version 16, reverting to cpu

If the current behavior is a bug, please provide the steps to reproduce.

ALTER DATABASE CURRENT
SET QUERY_STORE = ON ( WAIT_STATS_CAPTURE_MODE = OFF );

EXEC sp_QuickieStore @sort_order  = 'cpu waits';

What is the expected behavior?
Be honest. If storing wait stats has been disabled, then say that's the problem. The tricky thing here is that I don't know how we're going to solve that if @get_all_databases = 1.

Which versions of SQL Server and which OS are affected by this issue? Did this work in previous versions of our procedures?
2017+, I think.

IMPORTANT: If you're going to contribute code, please read the contributing guide first.
https://github.com/erikdarlingdata/DarlingData/blob/main/CONTRIBUTING.md
I'm happy to solve it if somebody gives me an idea of how to handle the case where some databases have wait stats but other don't.

Metadata

Metadata

Assignees

Labels

bugSomething isn't workingsp_QuickieStoreFor the loving of Query Store

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions