mirror of
https://github.com/Microsoft/sql-server-samples.git
synced 2025-12-08 14:58:54 +00:00
Added a json to fix QueryStore check + described it in readme
This commit is contained in:
@@ -0,0 +1,13 @@
|
||||
{
|
||||
"checks":[
|
||||
{
|
||||
"id": "SqlServer.Database.QueryStoreOn",
|
||||
"target":{
|
||||
"type": "Database",
|
||||
"version": "[13.0,)",
|
||||
"platform": "Windows",
|
||||
"name": { "not": "/^(master|tempdb)$/" }
|
||||
}
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -71,3 +71,12 @@ Demonstrates how to make a custom rule set containing two checks. The sample con
|
||||
}
|
||||
```
|
||||
|
||||
## QueryStoreCheck_fix.json
|
||||
|
||||
Overrides the default ruleset to fix the rule "Query Store should be on." Query Store appeared in SQL Server 2016 but the rule checks for it starting with SQL Server 2014.
|
||||
|
||||
Here's an example of applying the fix to running the InvokeSqlAssessment cmdlet.
|
||||
|
||||
```PowerShell
|
||||
Get-SqlInstance -ServerInstance 'localhost' | Get-SqlDatabase | Invoke-SqlAssessment -configuration "C:\SQLAssessment\QueryStore_fix.json"
|
||||
```
|
||||
|
||||
Reference in New Issue
Block a user