SlideShare a Scribd company logo
1 of 23
© 2019 IDERA, Inc. All rights reserved.
LEVERAGE THE QUERY STORE FOR BETTER
SQL SERVER PERFORMANCE
Presenter: Bullett Manale
VP of Sales Engineering
© 2019 IDERA, Inc. All rights reserved.
AGENDA
▪ Introduction to the Microsoft Query Store
▪ Getting Started and Best Practices
▪ Architecture
▪ Configuration and Options
▪ Enabling
▪ Query Store in the Cloud
▪ Configuring Query Store Using SQL Query Optimizer
▪ Reports
▪ Use Case Scenarios
▪ Leveraging SQL Query Store with SQL Diagnostic Manager
▪ Demonstration – SQL Diagnostic Manager
▪ Demonstration – DM Insights Available from the Azure Marketplace (Azure Data
Studio)
▪ Best Practices
▪ Troubleshooting
▪ Q&A
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 33
MICROSOFT SQL QUERY STORE
The Query Store, a feature
introduced with SQL
Server 2016, provides the
ability to collect and
historically review
information related to
execution plans, queries
and runtime statistics
associated to SQL Server
transactions.
The query store is often
referred to as the flight
data recorder for SQL
Server
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 4
GETTING STARTED WITH QUERY STORE
▪ Works on all Editions of SQL Server (2016, 2017)
▪ Is Configured at the Database Level
▪ Can be enabled using T-SQL or SSMS (version16 or higher) or SQL Azure
Data Studio
▪ Collects plans for DML that include, SELECT, INSERT, UPDATE,
DELETE, MERGE, and BULK INSERT.
▪ Query Store Data is Maintained in the Associated User Database Query
Store is Enabled on
▪ Cannot be Enabled for Master and TempDB System Databases
▪ Cannot be Used on Read-Only Databases
▪ The minimum permissions for using the SQL Server Query Store is VIEW
DATABASE STATE (Doesn’t include Force Plan and other admin commands)
▪ Available in the Cloud (more to follow on this)
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 5
HOW QUERY STORE WORKS
Runtime
Statistics
QUERY
STORE
Query Text
and Query
Plan
Memory
Written to
ASYNC
Queue
Immediately
Flushed to
ASYNC
Queue by
Default Every
15 Minutes
plan store contains persistent execution plan information
runtime stats store contains persistent execution statistics
wait stats store (2017) contains persistent wait statistics info
Query Store Schema
ASYNC
WRITER
Immediately Sent to Queue
Delay Based on Flush Rate
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 6
QUERY STORE CATALOG VIEWS
sys.database_query_store_options
sys.query_context_settings
sys.query_store_plan
sys.query_store_query
sys.query_store_query_text
sys.query_store_wait_stats (2017)
sys.query_store_runtime_stats
sys.query_store_runtime_stats_interval
https://docs.microsoft.com/en-us/sql/relational-databases/system-catalog-views/query-store-catalog-views-transact-sql?view=sql-server-2017
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 7
QUERY STORE STORED PROCEDURES
sp_query_store_consistency_check – Consistency Check, run when QS
is in Error State
sp_query_store_flush_db – Used to flush in-memory data to disk
sp_query_store_force_plan – Used to set a plan to forced
sp_query_store_remove_plan – Removes plan from query store
sp_query_store_remove_query – Removes query and associated plans &
runtime stats
sp_query_store_reset_exec_stats – Clear runtime stats for specific query
plan
sp_query_store_unforce_plan – Removes a plan from being forced
https://docs.microsoft.com/en-us/sql/relational-databases/system-stored-procedures/query-store-stored-procedures-transact-sql?view=sql-server-
2017
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 8
PRIMARY QUERY STORE SETTINGS
▪ Max Size - Default 100 MB, Azure DB Premium Edition 1GB, Azure Basic 10MB. Operation mode
switches to ‘Read’ when size is reached.
▪ Data Flush Interval (Minutes) – Default is 15. Begin on the default or higher setting initially, then
tune to lower value to mitigate performance data loss in the event of a failure. Other options include, 1,
5, 10, 15, 30 (minutes), 1 hour and 1 day.
▪ Query Store Capture Mode – Default is ALL. Determines the type of queries/plans that will be
captured and stored. AUTO will direct SQL Server to attempt to capture infrequent or ad-hoc queries.
▪ Size Based Cleanup Mode – Default is AUTO. When size of the query store reaches 90% of the
Max Size setting, queries will be chosen based on query execution time and likelihood of usefulness (ad-
hoc queries,etc). If set to OFF, data will not be groomed (unless based on stale queries) will ultimately
cause the Query Store State to change to READ.
▪ Stale Query Threshold (Days) – Default is 30. Retention period of the query store based on
persisted queries.
▪ Statistics Collection Interval – Default is 1 HOUR. Determines the frequency of aggregation of data.
This determines how
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 99
ENABLING QUERY STORE
In SQL Management Studio, enable Query Store by
right clicking the database, select properties; then
Click on the Query Store properties page and set
operation mode to Read Write
OR
In T-SQL:
ALTER DATABASE <DATABASE NAME> SET
QUERY_STORE = ON; /* Set to OFF to Disable */
Requires at least version 16 of Management Studio or Current Version of
Azure Data Studio to Enable in the GUI
• SQL Server 2016 & 2017: Query Store is Disabled by
Default
• Cloud Implementations: Enabled and Set to
Read/Write by Default
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 10
ENABLING THE QUERY STORE
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 11
USING QUERY STORE IN THE CLOUD
▪ Query Store is a Supported Feature on Both Azure DB and Amazon RDS
▪ Consumption Over Time and Identify Costly Performance Problems.
▪ Some settings are not configurable compared to on premise and
functionality may vary based on the service offering (Premium vs Basic).
▪ For AzureDB, use Query Performance Insight to analyze DTU
▪ Azure Data Studio does not currently support the same feature set within
the client compared to SQL Server Management Studio 18
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 12
SQL 2017 QUERY WAIT CATEGORIES
▪ Traditional wait types are now mapped to a category rather than
referencing the specific wait type.
▪ For example, instead of seeing ‘CX_Packet’ waits, you will now see
‘Parallelism’ as the Category.
▪ Arguably better than using the wait type (less confusing).
▪ Troubleshooting the category should be similar regardless of the
specific wait type.
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 13
WAIT TYPES MAPPED TO CATEGORY TYPES IN SQL 2017
WAIT CATEGORY WAIT TYPES INCLUDED WITHIN CATEGORY
CPU SOS_SCHEDULER_YIELD
Worker Thread THREADPOOL
Lock LCK_M_%
Latch LATCH_%
Buffer Latch PAGELATCH_%
Buffer IO PAGEIOLATCH_%
Compilation* RESOURCE_SEMAPHORE_QUERY_COMPILE
SQL CLR CLR%, SQLCLR%
Mirroring DBMIRROR%
Transaction XACT%, DTC%, TRAN_MARKLATCH_%, MSQL_XACT_%, TRANSACTION_MUTEX
Idle SLEEP_%, LAZYWRITER_SLEEP, SQLTRACE_BUFFER_FLUSH, SQLTRACE_INCREMENTAL_FLUSH_SLEEP, SQLTRACE_WAIT_ENTRIES,
FT_IFTS_SCHEDULER_IDLE_WAIT, XE_DISPATCHER_WAIT, REQUEST_FOR_DEADLOCK_SEARCH, LOGMGR_QUEUE, ONDEMAND_TASK_QUEUE,
CHECKPOINT_QUEUE, XE_TIMER_EVENT
Preemptive PREEMPTIVE_%
Service Broker BROKER_% (but not BROKER_RECEIVE_WAITFOR)
Tran Log IO LOGMGR, LOGBUFFER, LOGMGR_RESERVE_APPEND, LOGMGR_FLUSH, LOGMGR_PMM_LOG, CHKPT, WRITELOG
Network IO ASYNC_NETWORK_IO, NET_WAITFOR_PACKET, PROXY_NETWORK_IO, EXTERNAL_SCRIPT_NETWORK_IOF
Parallelism CXPACKET, EXCHANGE
Memory RESOURCE_SEMAPHORE, CMEMTHREAD, CMEMPARTITIONED, EE_PMOLOCK, MEMORY_ALLOCATION_EXT,
RESERVED_MEMORY_ALLOCATION_EXT, MEMORY_GRANT_UPDATE
User Wait WAITFOR, WAIT_FOR_RESULTS, BROKER_RECEIVE_WAITFOR
Tracing TRACEWRITE, SQLTRACE_LOCK, SQLTRACE_FILE_BUFFER, SQLTRACE_FILE_WRITE_IO_COMPLETION,
SQLTRACE_FILE_READ_IO_COMPLETION, SQLTRACE_PENDING_BUFFER_WRITERS, SQLTRACE_SHUTDOWN, QUERY_TRACEOUT,
TRACE_EVTNOTIFF
Full Text Search FT_RESTART_CRAWL, FULLTEXT GATHERER, MSSEARCH, FT_METADATA_MUTEX, FT_IFTSHC_MUTEX, FT_IFTSISM_MUTEX, FT_IFTS_RWLOCK,
FT_COMPROWSET_RWLOCK, FT_MASTER_MERGE, FT_PROPERTYLIST_CACHE, FT_MASTER_MERGE_COORDINATOR,
PWAIT_RESOURCE_SEMAPHORE_FT_PARALLEL_QUERY_SYNC
Other Disk IO ASYNC_IO_COMPLETION, IO_COMPLETION, BACKUPIO, WRITE_COMPLETION, IO_QUEUE_LIMIT, IO_RETRY
Replication SE_REPL_%, REPL_%, HADR_% (but not HADR_THROTTLE_LOG_RATE_GOVERNOR), PWAIT_HADR_%, REPLICA_WRITES, FCB_REPLICA_WRITE,
FCB_REPLICA_READ, PWAIT_HADRSIM
Log Rate Governor LOG_RATE_GOVERNOR, POOL_LOG_RATE_GOVERNOR, HADR_THROTTLE_LOG_RATE_GOVERNOR, INSTANCE_LOG_RATE_GOVERNOR
https://docs.microsoft.com/en-us/sql/relational-databases/system-catalog-views/sys-query-store-wait-stats-transact-sql?view=sql-server-
2017
© 2019 IDERA, Inc. All rights reserved. 14
BUILT IN REPORTS WITHIN THE SQL
QUERY STORE
▪ Regressed Queries
▪ Overall Resource Consumption
▪ Top Resource Consuming Queries
▪ Queries With Forced Plans
▪ Queries With High Variation
▪ Query Wait Statistics (2017 & Azure Only)
▪ Tracked Queries
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 15
USE CASE / SCENARIOS
▪ Finding the most expensive queries for CPU, I/O, and memory
▪ Getting full history of query executions and plans
▪ Getting information about query regressions, finding performance
regressions and fixing them by forcing the previous query plan whose
performance is better than a newly generated plan
▪ Ideal for A/B Testing
▪ Excellent tool for evaluating performance after upgrading
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 16
USE CASE SCENARIOS
▪ Pinpoint and fix queries with plan choice regressions
▪ Identify and tune top resource consuming queries
▪ A/B testing
▪ Keep performance stability during the upgrade to newer SQL Server
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 1717
QUERY STORE RECOMMENDED SETTINGS FOR
IDERA’S SQL DIAGNOSTIC MANAGER
ALTER DATABASE <database name>
SET QUERY_STORE = ON (
OPERATION_MODE = READ_WRITE, -- this is default
DATA_FLUSH_INTERVAL_SECONDS = 360, CLEANUP_POLICY =
(STALE_QUERY_THRESHOLD_DAYS = 30), -- this is default
MAX_STORAGE_SIZE_MB = 1024, -- 1 GB
INTERVAL_LENGTH_MINUTES = 15, -- defines aggregation
granularity, lower means more granular (default = 60)
SIZE_BASED_CLEANUP_MODE = AUTO, -- this is default, counter
balances size based cleanup (Cleanup Policy)
QUERY_CAPTURE_MODE = AUTO, -- helps to avoid collecting
infrequent or Ad Hoc based queries, Query Store will triage this for you
MAX_PLANS_PER_QUERY = 1000, -- default is 100, depends on
environment
WAIT_STATS_CAPTURE_MODE = ON -- default setting
);
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 1818
BEST PRACTICES
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 19
BEST PRACTICES
▪ Monitor the Query Store State to make sure the query store has not reverted to
read only mode.
▪ Monitor the rate of growth more closely upon initialization and as you get closer
to the end of the retention period.
▪ Make sure to remember to watch forced plans and their performance, don’t
forget about them!
▪ You can use the new performance counter objects available to capture
performance metrics related to the query store
▪ Always try to minimize unnecessary collection of the query store data taking all
factors into account.
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 20
TROUBLESHOOTING
▪ 1 - database is in read-only mode
2 - database is in single-user mode
4 - database is in emergency mode
8 - database is secondary replica (applies to Always On and Azure SQL Database geo-replication).
This value can be effectively observed only on readable secondary replicas
65536 - the Query Store has reached the size limit set by the MAX_STORAGE_SIZE_MB option.
131072 - The number of different statements in Query Store has reached the internal memory limit.
Consider removing queries that you do not need or upgrading to a higher service tier to enable
transferring Query Store to read-write mode.
Applies to: Azure SQL Database.
262144 - Size of in-memory items waiting to be persisted on disk has reached the internal memory
limit. Query Store will be in read-only mode temporarily until the in-memory items are persisted on
disk.
Applies to: Azure SQL Database.
524288 - Database has reached disk size limit. Query Store is part of user database, so if there is
no more available space for a database, that means that Query Store cannot grow further
anymore.
Applies to: Azure SQL Database.
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 21
https://docs.microsoft.com/en-us/sql/relational-databases/performance/monitoring-performance-by-using-the-query-store?view=sql-server-
2017
APPENDIX: MICROSOFT EXAMPLES OF
TROUBLESHOOTING NEW WAIT CATEGORIES
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 22
APPENDIX B: CONFIGURING QUERY STORE
▪ ALTER DATABASE <database name> SET QUERY_STORE (
OPERATION_MODE = READ_WRITE, CLEANUP_POLICY =
(STALE_QUERY_THRESHOLD_DAYS = 30),
DATA_FLUSH_INTERVAL_SECONDS = 3000,
MAX_STORAGE_SIZE_MB = 500, INTERVAL_LENGTH_MINUTES = 15,
SIZE_BASED_CLEANUP_MODE = AUTO, QUERY_CAPTURE_MODE =
AUTO, MAX_PLANS_PER_QUERY = 1000,
WAIT_STATS_CAPTURE_MODE = ON );
© 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 2323
THANKS!
Any questions?
You can find me at:
bullett.manale@idera.com

More Related Content

What's hot

Overview of Optimizer Features in 5.6 and 5.7-Manyi Lu
Overview of Optimizer Features in 5.6 and 5.7-Manyi LuOverview of Optimizer Features in 5.6 and 5.7-Manyi Lu
Overview of Optimizer Features in 5.6 and 5.7-Manyi Lu郁萍 王
 
Using MySQL Enterprise Monitor for Continuous Performance Improvement
Using MySQL Enterprise Monitor for Continuous Performance ImprovementUsing MySQL Enterprise Monitor for Continuous Performance Improvement
Using MySQL Enterprise Monitor for Continuous Performance ImprovementMark Matthews
 
VMware vCOPs Management Pack for Oracle Enterprise Manager
VMware vCOPs Management Pack for Oracle Enterprise ManagerVMware vCOPs Management Pack for Oracle Enterprise Manager
VMware vCOPs Management Pack for Oracle Enterprise ManagerBlue Medora
 
MySQL Enterprise Monitor
MySQL Enterprise MonitorMySQL Enterprise Monitor
MySQL Enterprise MonitorTed Wennmark
 
How to use Impala query plan and profile to fix performance issues
How to use Impala query plan and profile to fix performance issuesHow to use Impala query plan and profile to fix performance issues
How to use Impala query plan and profile to fix performance issuesCloudera, Inc.
 
What's New MySQL 8.0?
What's New MySQL 8.0?What's New MySQL 8.0?
What's New MySQL 8.0?OracleMySQL
 
Greenplum versus redshift and actian vectorwise comparison
Greenplum versus redshift and actian vectorwise comparisonGreenplum versus redshift and actian vectorwise comparison
Greenplum versus redshift and actian vectorwise comparisonDr. Syed Hassan Amin
 
MySQL For Linux Sysadmins
MySQL For Linux SysadminsMySQL For Linux Sysadmins
MySQL For Linux SysadminsMorgan Tocker
 
Earl Shaffer Oracle Performance Tuning pre12c 11g AWR uses
Earl Shaffer Oracle Performance Tuning pre12c 11g AWR usesEarl Shaffer Oracle Performance Tuning pre12c 11g AWR uses
Earl Shaffer Oracle Performance Tuning pre12c 11g AWR usesoramanc
 
Harnessing the Power of Optimizer Hints
Harnessing the Power of Optimizer HintsHarnessing the Power of Optimizer Hints
Harnessing the Power of Optimizer HintsMaria Colgan
 
MySQL 8.0 InnoDB Cluster demo
MySQL 8.0 InnoDB Cluster demoMySQL 8.0 InnoDB Cluster demo
MySQL 8.0 InnoDB Cluster demoKeith Hollman
 
Developing Applications with MySQL and Java
Developing Applications with MySQL and JavaDeveloping Applications with MySQL and Java
Developing Applications with MySQL and JavaMark Matthews
 
MySQL 5.7: What's New, Nov. 2015
MySQL 5.7: What's New, Nov. 2015MySQL 5.7: What's New, Nov. 2015
MySQL 5.7: What's New, Nov. 2015Mario Beck
 

What's hot (15)

Overview of Optimizer Features in 5.6 and 5.7-Manyi Lu
Overview of Optimizer Features in 5.6 and 5.7-Manyi LuOverview of Optimizer Features in 5.6 and 5.7-Manyi Lu
Overview of Optimizer Features in 5.6 and 5.7-Manyi Lu
 
Using MySQL Enterprise Monitor for Continuous Performance Improvement
Using MySQL Enterprise Monitor for Continuous Performance ImprovementUsing MySQL Enterprise Monitor for Continuous Performance Improvement
Using MySQL Enterprise Monitor for Continuous Performance Improvement
 
MySQL Cluster
MySQL ClusterMySQL Cluster
MySQL Cluster
 
VMware vCOPs Management Pack for Oracle Enterprise Manager
VMware vCOPs Management Pack for Oracle Enterprise ManagerVMware vCOPs Management Pack for Oracle Enterprise Manager
VMware vCOPs Management Pack for Oracle Enterprise Manager
 
MySQL Enterprise Monitor
MySQL Enterprise MonitorMySQL Enterprise Monitor
MySQL Enterprise Monitor
 
How to use Impala query plan and profile to fix performance issues
How to use Impala query plan and profile to fix performance issuesHow to use Impala query plan and profile to fix performance issues
How to use Impala query plan and profile to fix performance issues
 
What's New MySQL 8.0?
What's New MySQL 8.0?What's New MySQL 8.0?
What's New MySQL 8.0?
 
Greenplum versus redshift and actian vectorwise comparison
Greenplum versus redshift and actian vectorwise comparisonGreenplum versus redshift and actian vectorwise comparison
Greenplum versus redshift and actian vectorwise comparison
 
MySQL For Linux Sysadmins
MySQL For Linux SysadminsMySQL For Linux Sysadmins
MySQL For Linux Sysadmins
 
Earl Shaffer Oracle Performance Tuning pre12c 11g AWR uses
Earl Shaffer Oracle Performance Tuning pre12c 11g AWR usesEarl Shaffer Oracle Performance Tuning pre12c 11g AWR uses
Earl Shaffer Oracle Performance Tuning pre12c 11g AWR uses
 
MySQL-InnoDB
MySQL-InnoDBMySQL-InnoDB
MySQL-InnoDB
 
Harnessing the Power of Optimizer Hints
Harnessing the Power of Optimizer HintsHarnessing the Power of Optimizer Hints
Harnessing the Power of Optimizer Hints
 
MySQL 8.0 InnoDB Cluster demo
MySQL 8.0 InnoDB Cluster demoMySQL 8.0 InnoDB Cluster demo
MySQL 8.0 InnoDB Cluster demo
 
Developing Applications with MySQL and Java
Developing Applications with MySQL and JavaDeveloping Applications with MySQL and Java
Developing Applications with MySQL and Java
 
MySQL 5.7: What's New, Nov. 2015
MySQL 5.7: What's New, Nov. 2015MySQL 5.7: What's New, Nov. 2015
MySQL 5.7: What's New, Nov. 2015
 

Similar to IDERA Live | Leverage the Query Store for Better SQL Server Performance

Welcome To The 2016 Query Store!
Welcome To The 2016 Query Store!Welcome To The 2016 Query Store!
Welcome To The 2016 Query Store!SolarWinds
 
IDERA Slides: Managing Complex Data Environments
IDERA Slides: Managing Complex Data EnvironmentsIDERA Slides: Managing Complex Data Environments
IDERA Slides: Managing Complex Data EnvironmentsDATAVERSITY
 
MySQL 5.7 NEW FEATURES, BETTER PERFORMANCE, AND THINGS THAT WILL BREAK -- Mid...
MySQL 5.7 NEW FEATURES, BETTER PERFORMANCE, AND THINGS THAT WILL BREAK -- Mid...MySQL 5.7 NEW FEATURES, BETTER PERFORMANCE, AND THINGS THAT WILL BREAK -- Mid...
MySQL 5.7 NEW FEATURES, BETTER PERFORMANCE, AND THINGS THAT WILL BREAK -- Mid...Dave Stokes
 
MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014
MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014
MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014Dave Stokes
 
Live Query Statistics & Query Store in SQL Server 2016
Live Query Statistics & Query Store in SQL Server 2016Live Query Statistics & Query Store in SQL Server 2016
Live Query Statistics & Query Store in SQL Server 2016Antonios Chatzipavlis
 
MySQL Tech Tour 2015 - Manage & Tune
MySQL Tech Tour 2015 - Manage & TuneMySQL Tech Tour 2015 - Manage & Tune
MySQL Tech Tour 2015 - Manage & TuneMark Swarbrick
 
SQL Server Memory Pressure
SQL Server Memory PressureSQL Server Memory Pressure
SQL Server Memory PressureHamid J. Fard
 
How to analyze and tune sql queries for better performance vts2016
How to analyze and tune sql queries for better performance vts2016How to analyze and tune sql queries for better performance vts2016
How to analyze and tune sql queries for better performance vts2016oysteing
 
Upcoming changes in MySQL 5.7
Upcoming changes in MySQL 5.7Upcoming changes in MySQL 5.7
Upcoming changes in MySQL 5.7Morgan Tocker
 
IDERA Live | Working with Complex Data Environments
IDERA Live | Working with Complex Data EnvironmentsIDERA Live | Working with Complex Data Environments
IDERA Live | Working with Complex Data EnvironmentsIDERA Software
 
Idera live 2021: Performance Tuning Azure SQL Database by Monica Rathbun
Idera live 2021:  Performance Tuning Azure SQL Database by Monica RathbunIdera live 2021:  Performance Tuning Azure SQL Database by Monica Rathbun
Idera live 2021: Performance Tuning Azure SQL Database by Monica RathbunIDERA Software
 
Evolution of DBA in the Cloud Era
 Evolution of DBA in the Cloud Era Evolution of DBA in the Cloud Era
Evolution of DBA in the Cloud EraMydbops
 
MySQL Manchester TT - Performance Tuning
MySQL Manchester TT  - Performance TuningMySQL Manchester TT  - Performance Tuning
MySQL Manchester TT - Performance TuningMark Swarbrick
 
MySQL 5.7 -- SCaLE Feb 2014
MySQL 5.7 -- SCaLE Feb 2014MySQL 5.7 -- SCaLE Feb 2014
MySQL 5.7 -- SCaLE Feb 2014Dave Stokes
 
What is SQL Server 2019 Standard Edition
What is SQL Server 2019 Standard EditionWhat is SQL Server 2019 Standard Edition
What is SQL Server 2019 Standard EditionSoftwareDeals
 
Beyond SQL Tuning: Insider's Guide to Maximizing SQL Performance
Beyond SQL Tuning: Insider's Guide to Maximizing SQL PerformanceBeyond SQL Tuning: Insider's Guide to Maximizing SQL Performance
Beyond SQL Tuning: Insider's Guide to Maximizing SQL PerformanceAshish Agrawal
 
Advanced SQL - Quebec 2014
Advanced SQL - Quebec 2014Advanced SQL - Quebec 2014
Advanced SQL - Quebec 2014Connor McDonald
 
implementation of a big data architecture for real-time analytics with data s...
implementation of a big data architecture for real-time analytics with data s...implementation of a big data architecture for real-time analytics with data s...
implementation of a big data architecture for real-time analytics with data s...Joseph Arriola
 

Similar to IDERA Live | Leverage the Query Store for Better SQL Server Performance (20)

Welcome To The 2016 Query Store!
Welcome To The 2016 Query Store!Welcome To The 2016 Query Store!
Welcome To The 2016 Query Store!
 
IDERA Slides: Managing Complex Data Environments
IDERA Slides: Managing Complex Data EnvironmentsIDERA Slides: Managing Complex Data Environments
IDERA Slides: Managing Complex Data Environments
 
MySQL 5.7 NEW FEATURES, BETTER PERFORMANCE, AND THINGS THAT WILL BREAK -- Mid...
MySQL 5.7 NEW FEATURES, BETTER PERFORMANCE, AND THINGS THAT WILL BREAK -- Mid...MySQL 5.7 NEW FEATURES, BETTER PERFORMANCE, AND THINGS THAT WILL BREAK -- Mid...
MySQL 5.7 NEW FEATURES, BETTER PERFORMANCE, AND THINGS THAT WILL BREAK -- Mid...
 
MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014
MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014
MySQL 5.7 New Features to Exploit -- PHPTek/Chicago MySQL User Group May 2014
 
Live Query Statistics & Query Store in SQL Server 2016
Live Query Statistics & Query Store in SQL Server 2016Live Query Statistics & Query Store in SQL Server 2016
Live Query Statistics & Query Store in SQL Server 2016
 
MySQL Tech Tour 2015 - Manage & Tune
MySQL Tech Tour 2015 - Manage & TuneMySQL Tech Tour 2015 - Manage & Tune
MySQL Tech Tour 2015 - Manage & Tune
 
SQL Server Memory Pressure
SQL Server Memory PressureSQL Server Memory Pressure
SQL Server Memory Pressure
 
How to analyze and tune sql queries for better performance vts2016
How to analyze and tune sql queries for better performance vts2016How to analyze and tune sql queries for better performance vts2016
How to analyze and tune sql queries for better performance vts2016
 
AWR, ASH with EM13 at HotSos 2016
AWR, ASH with EM13 at HotSos 2016AWR, ASH with EM13 at HotSos 2016
AWR, ASH with EM13 at HotSos 2016
 
Upcoming changes in MySQL 5.7
Upcoming changes in MySQL 5.7Upcoming changes in MySQL 5.7
Upcoming changes in MySQL 5.7
 
IDERA Live | Working with Complex Data Environments
IDERA Live | Working with Complex Data EnvironmentsIDERA Live | Working with Complex Data Environments
IDERA Live | Working with Complex Data Environments
 
Idera live 2021: Performance Tuning Azure SQL Database by Monica Rathbun
Idera live 2021:  Performance Tuning Azure SQL Database by Monica RathbunIdera live 2021:  Performance Tuning Azure SQL Database by Monica Rathbun
Idera live 2021: Performance Tuning Azure SQL Database by Monica Rathbun
 
MySQL Tech Tour Nov, 2013
MySQL Tech Tour Nov, 2013MySQL Tech Tour Nov, 2013
MySQL Tech Tour Nov, 2013
 
Evolution of DBA in the Cloud Era
 Evolution of DBA in the Cloud Era Evolution of DBA in the Cloud Era
Evolution of DBA in the Cloud Era
 
MySQL Manchester TT - Performance Tuning
MySQL Manchester TT  - Performance TuningMySQL Manchester TT  - Performance Tuning
MySQL Manchester TT - Performance Tuning
 
MySQL 5.7 -- SCaLE Feb 2014
MySQL 5.7 -- SCaLE Feb 2014MySQL 5.7 -- SCaLE Feb 2014
MySQL 5.7 -- SCaLE Feb 2014
 
What is SQL Server 2019 Standard Edition
What is SQL Server 2019 Standard EditionWhat is SQL Server 2019 Standard Edition
What is SQL Server 2019 Standard Edition
 
Beyond SQL Tuning: Insider's Guide to Maximizing SQL Performance
Beyond SQL Tuning: Insider's Guide to Maximizing SQL PerformanceBeyond SQL Tuning: Insider's Guide to Maximizing SQL Performance
Beyond SQL Tuning: Insider's Guide to Maximizing SQL Performance
 
Advanced SQL - Quebec 2014
Advanced SQL - Quebec 2014Advanced SQL - Quebec 2014
Advanced SQL - Quebec 2014
 
implementation of a big data architecture for real-time analytics with data s...
implementation of a big data architecture for real-time analytics with data s...implementation of a big data architecture for real-time analytics with data s...
implementation of a big data architecture for real-time analytics with data s...
 

More from IDERA Software

The role of the database administrator (DBA) in 2020: Changes, challenges, an...
The role of the database administrator (DBA) in 2020: Changes, challenges, an...The role of the database administrator (DBA) in 2020: Changes, challenges, an...
The role of the database administrator (DBA) in 2020: Changes, challenges, an...IDERA Software
 
Problems and solutions for migrating databases to the cloud
Problems and solutions for migrating databases to the cloudProblems and solutions for migrating databases to the cloud
Problems and solutions for migrating databases to the cloudIDERA Software
 
Public cloud uses and limitations
Public cloud uses and limitationsPublic cloud uses and limitations
Public cloud uses and limitationsIDERA Software
 
Optimize the performance, cost, and value of databases.pptx
Optimize the performance, cost, and value of databases.pptxOptimize the performance, cost, and value of databases.pptx
Optimize the performance, cost, and value of databases.pptxIDERA Software
 
Monitor cloud database with SQL Diagnostic Manager for SQL Server
Monitor cloud database with SQL Diagnostic Manager for SQL ServerMonitor cloud database with SQL Diagnostic Manager for SQL Server
Monitor cloud database with SQL Diagnostic Manager for SQL ServerIDERA Software
 
Database administrators (dbas) face increasing pressure to monitor databases
Database administrators (dbas) face increasing pressure to monitor databasesDatabase administrators (dbas) face increasing pressure to monitor databases
Database administrators (dbas) face increasing pressure to monitor databasesIDERA Software
 
Six tips for cutting sql server licensing costs
Six tips for cutting sql server licensing costsSix tips for cutting sql server licensing costs
Six tips for cutting sql server licensing costsIDERA Software
 
Idera live 2021: The Power of Abstraction by Steve Hoberman
Idera live 2021:  The Power of Abstraction by Steve HobermanIdera live 2021:  The Power of Abstraction by Steve Hoberman
Idera live 2021: The Power of Abstraction by Steve HobermanIDERA Software
 
Idera live 2021: Why Data Lakes are Critical for AI, ML, and IoT By Brian Flug
Idera live 2021:  Why Data Lakes are Critical for AI, ML, and IoT  By Brian FlugIdera live 2021:  Why Data Lakes are Critical for AI, ML, and IoT  By Brian Flug
Idera live 2021: Why Data Lakes are Critical for AI, ML, and IoT By Brian FlugIDERA Software
 
Idera live 2021: Will Data Vault add Value to Your Data Warehouse? 3 Signs th...
Idera live 2021: Will Data Vault add Value to Your Data Warehouse? 3 Signs th...Idera live 2021: Will Data Vault add Value to Your Data Warehouse? 3 Signs th...
Idera live 2021: Will Data Vault add Value to Your Data Warehouse? 3 Signs th...IDERA Software
 
Idera live 2021: Managing Digital Transformation on a Budget by Bert Scalzo
Idera live 2021:  Managing Digital Transformation on a Budget by Bert ScalzoIdera live 2021:  Managing Digital Transformation on a Budget by Bert Scalzo
Idera live 2021: Managing Digital Transformation on a Budget by Bert ScalzoIDERA Software
 
Idera live 2021: Keynote Presentation The Future of Data is The Data Cloud b...
Idera live 2021:  Keynote Presentation The Future of Data is The Data Cloud b...Idera live 2021:  Keynote Presentation The Future of Data is The Data Cloud b...
Idera live 2021: Keynote Presentation The Future of Data is The Data Cloud b...IDERA Software
 
Idera live 2021: Managing Databases in the Cloud - the First Step, a Succes...
Idera live 2021:   Managing Databases in the Cloud - the First Step, a Succes...Idera live 2021:   Managing Databases in the Cloud - the First Step, a Succes...
Idera live 2021: Managing Databases in the Cloud - the First Step, a Succes...IDERA Software
 
Idera live 2021: Database Auditing - on-Premises and in the Cloud by Craig M...
Idera live 2021:  Database Auditing - on-Premises and in the Cloud by Craig M...Idera live 2021:  Database Auditing - on-Premises and in the Cloud by Craig M...
Idera live 2021: Database Auditing - on-Premises and in the Cloud by Craig M...IDERA Software
 
Geek Sync | How to Be the DBA When You Don't Have a DBA - Eric Cobb | IDERA
Geek Sync | How to Be the DBA When You Don't Have a DBA - Eric Cobb | IDERAGeek Sync | How to Be the DBA When You Don't Have a DBA - Eric Cobb | IDERA
Geek Sync | How to Be the DBA When You Don't Have a DBA - Eric Cobb | IDERAIDERA Software
 
How Users of a Performance Monitoring Tool Can Benefit from an Inventory Mana...
How Users of a Performance Monitoring Tool Can Benefit from an Inventory Mana...How Users of a Performance Monitoring Tool Can Benefit from an Inventory Mana...
How Users of a Performance Monitoring Tool Can Benefit from an Inventory Mana...IDERA Software
 
Benefits of Third Party Tools for MySQL | IDERA
Benefits of Third Party Tools for MySQL | IDERABenefits of Third Party Tools for MySQL | IDERA
Benefits of Third Party Tools for MySQL | IDERAIDERA Software
 
Achieve More with Less Resources | IDERA
Achieve More with Less Resources | IDERAAchieve More with Less Resources | IDERA
Achieve More with Less Resources | IDERAIDERA Software
 
Benefits of SQL Server 2017 and 2019 | IDERA
Benefits of SQL Server 2017 and 2019 | IDERABenefits of SQL Server 2017 and 2019 | IDERA
Benefits of SQL Server 2017 and 2019 | IDERAIDERA Software
 
Be Proactive: A Good DBA Goes Looking for Signs of Trouble | IDERA
Be Proactive: A Good DBA Goes Looking for Signs of Trouble | IDERABe Proactive: A Good DBA Goes Looking for Signs of Trouble | IDERA
Be Proactive: A Good DBA Goes Looking for Signs of Trouble | IDERAIDERA Software
 

More from IDERA Software (20)

The role of the database administrator (DBA) in 2020: Changes, challenges, an...
The role of the database administrator (DBA) in 2020: Changes, challenges, an...The role of the database administrator (DBA) in 2020: Changes, challenges, an...
The role of the database administrator (DBA) in 2020: Changes, challenges, an...
 
Problems and solutions for migrating databases to the cloud
Problems and solutions for migrating databases to the cloudProblems and solutions for migrating databases to the cloud
Problems and solutions for migrating databases to the cloud
 
Public cloud uses and limitations
Public cloud uses and limitationsPublic cloud uses and limitations
Public cloud uses and limitations
 
Optimize the performance, cost, and value of databases.pptx
Optimize the performance, cost, and value of databases.pptxOptimize the performance, cost, and value of databases.pptx
Optimize the performance, cost, and value of databases.pptx
 
Monitor cloud database with SQL Diagnostic Manager for SQL Server
Monitor cloud database with SQL Diagnostic Manager for SQL ServerMonitor cloud database with SQL Diagnostic Manager for SQL Server
Monitor cloud database with SQL Diagnostic Manager for SQL Server
 
Database administrators (dbas) face increasing pressure to monitor databases
Database administrators (dbas) face increasing pressure to monitor databasesDatabase administrators (dbas) face increasing pressure to monitor databases
Database administrators (dbas) face increasing pressure to monitor databases
 
Six tips for cutting sql server licensing costs
Six tips for cutting sql server licensing costsSix tips for cutting sql server licensing costs
Six tips for cutting sql server licensing costs
 
Idera live 2021: The Power of Abstraction by Steve Hoberman
Idera live 2021:  The Power of Abstraction by Steve HobermanIdera live 2021:  The Power of Abstraction by Steve Hoberman
Idera live 2021: The Power of Abstraction by Steve Hoberman
 
Idera live 2021: Why Data Lakes are Critical for AI, ML, and IoT By Brian Flug
Idera live 2021:  Why Data Lakes are Critical for AI, ML, and IoT  By Brian FlugIdera live 2021:  Why Data Lakes are Critical for AI, ML, and IoT  By Brian Flug
Idera live 2021: Why Data Lakes are Critical for AI, ML, and IoT By Brian Flug
 
Idera live 2021: Will Data Vault add Value to Your Data Warehouse? 3 Signs th...
Idera live 2021: Will Data Vault add Value to Your Data Warehouse? 3 Signs th...Idera live 2021: Will Data Vault add Value to Your Data Warehouse? 3 Signs th...
Idera live 2021: Will Data Vault add Value to Your Data Warehouse? 3 Signs th...
 
Idera live 2021: Managing Digital Transformation on a Budget by Bert Scalzo
Idera live 2021:  Managing Digital Transformation on a Budget by Bert ScalzoIdera live 2021:  Managing Digital Transformation on a Budget by Bert Scalzo
Idera live 2021: Managing Digital Transformation on a Budget by Bert Scalzo
 
Idera live 2021: Keynote Presentation The Future of Data is The Data Cloud b...
Idera live 2021:  Keynote Presentation The Future of Data is The Data Cloud b...Idera live 2021:  Keynote Presentation The Future of Data is The Data Cloud b...
Idera live 2021: Keynote Presentation The Future of Data is The Data Cloud b...
 
Idera live 2021: Managing Databases in the Cloud - the First Step, a Succes...
Idera live 2021:   Managing Databases in the Cloud - the First Step, a Succes...Idera live 2021:   Managing Databases in the Cloud - the First Step, a Succes...
Idera live 2021: Managing Databases in the Cloud - the First Step, a Succes...
 
Idera live 2021: Database Auditing - on-Premises and in the Cloud by Craig M...
Idera live 2021:  Database Auditing - on-Premises and in the Cloud by Craig M...Idera live 2021:  Database Auditing - on-Premises and in the Cloud by Craig M...
Idera live 2021: Database Auditing - on-Premises and in the Cloud by Craig M...
 
Geek Sync | How to Be the DBA When You Don't Have a DBA - Eric Cobb | IDERA
Geek Sync | How to Be the DBA When You Don't Have a DBA - Eric Cobb | IDERAGeek Sync | How to Be the DBA When You Don't Have a DBA - Eric Cobb | IDERA
Geek Sync | How to Be the DBA When You Don't Have a DBA - Eric Cobb | IDERA
 
How Users of a Performance Monitoring Tool Can Benefit from an Inventory Mana...
How Users of a Performance Monitoring Tool Can Benefit from an Inventory Mana...How Users of a Performance Monitoring Tool Can Benefit from an Inventory Mana...
How Users of a Performance Monitoring Tool Can Benefit from an Inventory Mana...
 
Benefits of Third Party Tools for MySQL | IDERA
Benefits of Third Party Tools for MySQL | IDERABenefits of Third Party Tools for MySQL | IDERA
Benefits of Third Party Tools for MySQL | IDERA
 
Achieve More with Less Resources | IDERA
Achieve More with Less Resources | IDERAAchieve More with Less Resources | IDERA
Achieve More with Less Resources | IDERA
 
Benefits of SQL Server 2017 and 2019 | IDERA
Benefits of SQL Server 2017 and 2019 | IDERABenefits of SQL Server 2017 and 2019 | IDERA
Benefits of SQL Server 2017 and 2019 | IDERA
 
Be Proactive: A Good DBA Goes Looking for Signs of Trouble | IDERA
Be Proactive: A Good DBA Goes Looking for Signs of Trouble | IDERABe Proactive: A Good DBA Goes Looking for Signs of Trouble | IDERA
Be Proactive: A Good DBA Goes Looking for Signs of Trouble | IDERA
 

Recently uploaded

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...shyamraj55
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksSoftradix Technologies
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii SoldatenkoFwdays
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024Scott Keck-Warren
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr BaganFwdays
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebUiPathCommunity
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 3652toLead Limited
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfAddepto
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Scott Keck-Warren
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfjimielynbastida
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Commit University
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Mattias Andersson
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brandgvaughan
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsRizwan Syed
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDGMarianaLemus7
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsMark Billinghurst
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationSlibray Presentation
 

Recently uploaded (20)

Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
Automating Business Process via MuleSoft Composer | Bangalore MuleSoft Meetup...
 
Benefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other FrameworksBenefits Of Flutter Compared To Other Frameworks
Benefits Of Flutter Compared To Other Frameworks
 
"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko"Debugging python applications inside k8s environment", Andrii Soldatenko
"Debugging python applications inside k8s environment", Andrii Soldatenko
 
Pigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food ManufacturingPigging Solutions in Pet Food Manufacturing
Pigging Solutions in Pet Food Manufacturing
 
SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024SQL Database Design For Developers at php[tek] 2024
SQL Database Design For Developers at php[tek] 2024
 
"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan"ML in Production",Oleksandr Bagan
"ML in Production",Oleksandr Bagan
 
Dev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio WebDev Dives: Streamline document processing with UiPath Studio Web
Dev Dives: Streamline document processing with UiPath Studio Web
 
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
Tech-Forward - Achieving Business Readiness For Copilot in Microsoft 365
 
Gen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdfGen AI in Business - Global Trends Report 2024.pdf
Gen AI in Business - Global Trends Report 2024.pdf
 
Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024Advanced Test Driven-Development @ php[tek] 2024
Advanced Test Driven-Development @ php[tek] 2024
 
Science&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdfScience&tech:THE INFORMATION AGE STS.pdf
Science&tech:THE INFORMATION AGE STS.pdf
 
Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!Nell’iperspazio con Rocket: il Framework Web di Rust!
Nell’iperspazio con Rocket: il Framework Web di Rust!
 
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort ServiceHot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
Hot Sexy call girls in Panjabi Bagh 🔝 9953056974 🔝 Delhi escort Service
 
Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?Are Multi-Cloud and Serverless Good or Bad?
Are Multi-Cloud and Serverless Good or Bad?
 
WordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your BrandWordPress Websites for Engineers: Elevate Your Brand
WordPress Websites for Engineers: Elevate Your Brand
 
Scanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL CertsScanning the Internet for External Cloud Exposures via SSL Certs
Scanning the Internet for External Cloud Exposures via SSL Certs
 
APIForce Zurich 5 April Automation LPDG
APIForce Zurich 5 April  Automation LPDGAPIForce Zurich 5 April  Automation LPDG
APIForce Zurich 5 April Automation LPDG
 
Human Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR SystemsHuman Factors of XR: Using Human Factors to Design XR Systems
Human Factors of XR: Using Human Factors to Design XR Systems
 
DMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special EditionDMCC Future of Trade Web3 - Special Edition
DMCC Future of Trade Web3 - Special Edition
 
Connect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck PresentationConnect Wave/ connectwave Pitch Deck Presentation
Connect Wave/ connectwave Pitch Deck Presentation
 

IDERA Live | Leverage the Query Store for Better SQL Server Performance

  • 1. © 2019 IDERA, Inc. All rights reserved. LEVERAGE THE QUERY STORE FOR BETTER SQL SERVER PERFORMANCE Presenter: Bullett Manale VP of Sales Engineering
  • 2. © 2019 IDERA, Inc. All rights reserved. AGENDA ▪ Introduction to the Microsoft Query Store ▪ Getting Started and Best Practices ▪ Architecture ▪ Configuration and Options ▪ Enabling ▪ Query Store in the Cloud ▪ Configuring Query Store Using SQL Query Optimizer ▪ Reports ▪ Use Case Scenarios ▪ Leveraging SQL Query Store with SQL Diagnostic Manager ▪ Demonstration – SQL Diagnostic Manager ▪ Demonstration – DM Insights Available from the Azure Marketplace (Azure Data Studio) ▪ Best Practices ▪ Troubleshooting ▪ Q&A
  • 3. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 33 MICROSOFT SQL QUERY STORE The Query Store, a feature introduced with SQL Server 2016, provides the ability to collect and historically review information related to execution plans, queries and runtime statistics associated to SQL Server transactions. The query store is often referred to as the flight data recorder for SQL Server
  • 4. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 4 GETTING STARTED WITH QUERY STORE ▪ Works on all Editions of SQL Server (2016, 2017) ▪ Is Configured at the Database Level ▪ Can be enabled using T-SQL or SSMS (version16 or higher) or SQL Azure Data Studio ▪ Collects plans for DML that include, SELECT, INSERT, UPDATE, DELETE, MERGE, and BULK INSERT. ▪ Query Store Data is Maintained in the Associated User Database Query Store is Enabled on ▪ Cannot be Enabled for Master and TempDB System Databases ▪ Cannot be Used on Read-Only Databases ▪ The minimum permissions for using the SQL Server Query Store is VIEW DATABASE STATE (Doesn’t include Force Plan and other admin commands) ▪ Available in the Cloud (more to follow on this)
  • 5. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 5 HOW QUERY STORE WORKS Runtime Statistics QUERY STORE Query Text and Query Plan Memory Written to ASYNC Queue Immediately Flushed to ASYNC Queue by Default Every 15 Minutes plan store contains persistent execution plan information runtime stats store contains persistent execution statistics wait stats store (2017) contains persistent wait statistics info Query Store Schema ASYNC WRITER Immediately Sent to Queue Delay Based on Flush Rate
  • 6. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 6 QUERY STORE CATALOG VIEWS sys.database_query_store_options sys.query_context_settings sys.query_store_plan sys.query_store_query sys.query_store_query_text sys.query_store_wait_stats (2017) sys.query_store_runtime_stats sys.query_store_runtime_stats_interval https://docs.microsoft.com/en-us/sql/relational-databases/system-catalog-views/query-store-catalog-views-transact-sql?view=sql-server-2017
  • 7. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 7 QUERY STORE STORED PROCEDURES sp_query_store_consistency_check – Consistency Check, run when QS is in Error State sp_query_store_flush_db – Used to flush in-memory data to disk sp_query_store_force_plan – Used to set a plan to forced sp_query_store_remove_plan – Removes plan from query store sp_query_store_remove_query – Removes query and associated plans & runtime stats sp_query_store_reset_exec_stats – Clear runtime stats for specific query plan sp_query_store_unforce_plan – Removes a plan from being forced https://docs.microsoft.com/en-us/sql/relational-databases/system-stored-procedures/query-store-stored-procedures-transact-sql?view=sql-server- 2017
  • 8. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 8 PRIMARY QUERY STORE SETTINGS ▪ Max Size - Default 100 MB, Azure DB Premium Edition 1GB, Azure Basic 10MB. Operation mode switches to ‘Read’ when size is reached. ▪ Data Flush Interval (Minutes) – Default is 15. Begin on the default or higher setting initially, then tune to lower value to mitigate performance data loss in the event of a failure. Other options include, 1, 5, 10, 15, 30 (minutes), 1 hour and 1 day. ▪ Query Store Capture Mode – Default is ALL. Determines the type of queries/plans that will be captured and stored. AUTO will direct SQL Server to attempt to capture infrequent or ad-hoc queries. ▪ Size Based Cleanup Mode – Default is AUTO. When size of the query store reaches 90% of the Max Size setting, queries will be chosen based on query execution time and likelihood of usefulness (ad- hoc queries,etc). If set to OFF, data will not be groomed (unless based on stale queries) will ultimately cause the Query Store State to change to READ. ▪ Stale Query Threshold (Days) – Default is 30. Retention period of the query store based on persisted queries. ▪ Statistics Collection Interval – Default is 1 HOUR. Determines the frequency of aggregation of data. This determines how
  • 9. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 99 ENABLING QUERY STORE In SQL Management Studio, enable Query Store by right clicking the database, select properties; then Click on the Query Store properties page and set operation mode to Read Write OR In T-SQL: ALTER DATABASE <DATABASE NAME> SET QUERY_STORE = ON; /* Set to OFF to Disable */ Requires at least version 16 of Management Studio or Current Version of Azure Data Studio to Enable in the GUI • SQL Server 2016 & 2017: Query Store is Disabled by Default • Cloud Implementations: Enabled and Set to Read/Write by Default
  • 10. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 10 ENABLING THE QUERY STORE
  • 11. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 11 USING QUERY STORE IN THE CLOUD ▪ Query Store is a Supported Feature on Both Azure DB and Amazon RDS ▪ Consumption Over Time and Identify Costly Performance Problems. ▪ Some settings are not configurable compared to on premise and functionality may vary based on the service offering (Premium vs Basic). ▪ For AzureDB, use Query Performance Insight to analyze DTU ▪ Azure Data Studio does not currently support the same feature set within the client compared to SQL Server Management Studio 18
  • 12. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 12 SQL 2017 QUERY WAIT CATEGORIES ▪ Traditional wait types are now mapped to a category rather than referencing the specific wait type. ▪ For example, instead of seeing ‘CX_Packet’ waits, you will now see ‘Parallelism’ as the Category. ▪ Arguably better than using the wait type (less confusing). ▪ Troubleshooting the category should be similar regardless of the specific wait type.
  • 13. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 13 WAIT TYPES MAPPED TO CATEGORY TYPES IN SQL 2017 WAIT CATEGORY WAIT TYPES INCLUDED WITHIN CATEGORY CPU SOS_SCHEDULER_YIELD Worker Thread THREADPOOL Lock LCK_M_% Latch LATCH_% Buffer Latch PAGELATCH_% Buffer IO PAGEIOLATCH_% Compilation* RESOURCE_SEMAPHORE_QUERY_COMPILE SQL CLR CLR%, SQLCLR% Mirroring DBMIRROR% Transaction XACT%, DTC%, TRAN_MARKLATCH_%, MSQL_XACT_%, TRANSACTION_MUTEX Idle SLEEP_%, LAZYWRITER_SLEEP, SQLTRACE_BUFFER_FLUSH, SQLTRACE_INCREMENTAL_FLUSH_SLEEP, SQLTRACE_WAIT_ENTRIES, FT_IFTS_SCHEDULER_IDLE_WAIT, XE_DISPATCHER_WAIT, REQUEST_FOR_DEADLOCK_SEARCH, LOGMGR_QUEUE, ONDEMAND_TASK_QUEUE, CHECKPOINT_QUEUE, XE_TIMER_EVENT Preemptive PREEMPTIVE_% Service Broker BROKER_% (but not BROKER_RECEIVE_WAITFOR) Tran Log IO LOGMGR, LOGBUFFER, LOGMGR_RESERVE_APPEND, LOGMGR_FLUSH, LOGMGR_PMM_LOG, CHKPT, WRITELOG Network IO ASYNC_NETWORK_IO, NET_WAITFOR_PACKET, PROXY_NETWORK_IO, EXTERNAL_SCRIPT_NETWORK_IOF Parallelism CXPACKET, EXCHANGE Memory RESOURCE_SEMAPHORE, CMEMTHREAD, CMEMPARTITIONED, EE_PMOLOCK, MEMORY_ALLOCATION_EXT, RESERVED_MEMORY_ALLOCATION_EXT, MEMORY_GRANT_UPDATE User Wait WAITFOR, WAIT_FOR_RESULTS, BROKER_RECEIVE_WAITFOR Tracing TRACEWRITE, SQLTRACE_LOCK, SQLTRACE_FILE_BUFFER, SQLTRACE_FILE_WRITE_IO_COMPLETION, SQLTRACE_FILE_READ_IO_COMPLETION, SQLTRACE_PENDING_BUFFER_WRITERS, SQLTRACE_SHUTDOWN, QUERY_TRACEOUT, TRACE_EVTNOTIFF Full Text Search FT_RESTART_CRAWL, FULLTEXT GATHERER, MSSEARCH, FT_METADATA_MUTEX, FT_IFTSHC_MUTEX, FT_IFTSISM_MUTEX, FT_IFTS_RWLOCK, FT_COMPROWSET_RWLOCK, FT_MASTER_MERGE, FT_PROPERTYLIST_CACHE, FT_MASTER_MERGE_COORDINATOR, PWAIT_RESOURCE_SEMAPHORE_FT_PARALLEL_QUERY_SYNC Other Disk IO ASYNC_IO_COMPLETION, IO_COMPLETION, BACKUPIO, WRITE_COMPLETION, IO_QUEUE_LIMIT, IO_RETRY Replication SE_REPL_%, REPL_%, HADR_% (but not HADR_THROTTLE_LOG_RATE_GOVERNOR), PWAIT_HADR_%, REPLICA_WRITES, FCB_REPLICA_WRITE, FCB_REPLICA_READ, PWAIT_HADRSIM Log Rate Governor LOG_RATE_GOVERNOR, POOL_LOG_RATE_GOVERNOR, HADR_THROTTLE_LOG_RATE_GOVERNOR, INSTANCE_LOG_RATE_GOVERNOR https://docs.microsoft.com/en-us/sql/relational-databases/system-catalog-views/sys-query-store-wait-stats-transact-sql?view=sql-server- 2017
  • 14. © 2019 IDERA, Inc. All rights reserved. 14 BUILT IN REPORTS WITHIN THE SQL QUERY STORE ▪ Regressed Queries ▪ Overall Resource Consumption ▪ Top Resource Consuming Queries ▪ Queries With Forced Plans ▪ Queries With High Variation ▪ Query Wait Statistics (2017 & Azure Only) ▪ Tracked Queries
  • 15. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 15 USE CASE / SCENARIOS ▪ Finding the most expensive queries for CPU, I/O, and memory ▪ Getting full history of query executions and plans ▪ Getting information about query regressions, finding performance regressions and fixing them by forcing the previous query plan whose performance is better than a newly generated plan ▪ Ideal for A/B Testing ▪ Excellent tool for evaluating performance after upgrading
  • 16. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 16 USE CASE SCENARIOS ▪ Pinpoint and fix queries with plan choice regressions ▪ Identify and tune top resource consuming queries ▪ A/B testing ▪ Keep performance stability during the upgrade to newer SQL Server
  • 17. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 1717 QUERY STORE RECOMMENDED SETTINGS FOR IDERA’S SQL DIAGNOSTIC MANAGER ALTER DATABASE <database name> SET QUERY_STORE = ON ( OPERATION_MODE = READ_WRITE, -- this is default DATA_FLUSH_INTERVAL_SECONDS = 360, CLEANUP_POLICY = (STALE_QUERY_THRESHOLD_DAYS = 30), -- this is default MAX_STORAGE_SIZE_MB = 1024, -- 1 GB INTERVAL_LENGTH_MINUTES = 15, -- defines aggregation granularity, lower means more granular (default = 60) SIZE_BASED_CLEANUP_MODE = AUTO, -- this is default, counter balances size based cleanup (Cleanup Policy) QUERY_CAPTURE_MODE = AUTO, -- helps to avoid collecting infrequent or Ad Hoc based queries, Query Store will triage this for you MAX_PLANS_PER_QUERY = 1000, -- default is 100, depends on environment WAIT_STATS_CAPTURE_MODE = ON -- default setting );
  • 18. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 1818 BEST PRACTICES
  • 19. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 19 BEST PRACTICES ▪ Monitor the Query Store State to make sure the query store has not reverted to read only mode. ▪ Monitor the rate of growth more closely upon initialization and as you get closer to the end of the retention period. ▪ Make sure to remember to watch forced plans and their performance, don’t forget about them! ▪ You can use the new performance counter objects available to capture performance metrics related to the query store ▪ Always try to minimize unnecessary collection of the query store data taking all factors into account.
  • 20. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 20 TROUBLESHOOTING ▪ 1 - database is in read-only mode 2 - database is in single-user mode 4 - database is in emergency mode 8 - database is secondary replica (applies to Always On and Azure SQL Database geo-replication). This value can be effectively observed only on readable secondary replicas 65536 - the Query Store has reached the size limit set by the MAX_STORAGE_SIZE_MB option. 131072 - The number of different statements in Query Store has reached the internal memory limit. Consider removing queries that you do not need or upgrading to a higher service tier to enable transferring Query Store to read-write mode. Applies to: Azure SQL Database. 262144 - Size of in-memory items waiting to be persisted on disk has reached the internal memory limit. Query Store will be in read-only mode temporarily until the in-memory items are persisted on disk. Applies to: Azure SQL Database. 524288 - Database has reached disk size limit. Query Store is part of user database, so if there is no more available space for a database, that means that Query Store cannot grow further anymore. Applies to: Azure SQL Database.
  • 21. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 21 https://docs.microsoft.com/en-us/sql/relational-databases/performance/monitoring-performance-by-using-the-query-store?view=sql-server- 2017 APPENDIX: MICROSOFT EXAMPLES OF TROUBLESHOOTING NEW WAIT CATEGORIES
  • 22. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 22 APPENDIX B: CONFIGURING QUERY STORE ▪ ALTER DATABASE <database name> SET QUERY_STORE ( OPERATION_MODE = READ_WRITE, CLEANUP_POLICY = (STALE_QUERY_THRESHOLD_DAYS = 30), DATA_FLUSH_INTERVAL_SECONDS = 3000, MAX_STORAGE_SIZE_MB = 500, INTERVAL_LENGTH_MINUTES = 15, SIZE_BASED_CLEANUP_MODE = AUTO, QUERY_CAPTURE_MODE = AUTO, MAX_PLANS_PER_QUERY = 1000, WAIT_STATS_CAPTURE_MODE = ON );
  • 23. © 2016 IDERA, Inc. All rights reserved. Proprietary and confidential.© 2019 IDERA, Inc. All rights reserved. 2323 THANKS! Any questions? You can find me at: bullett.manale@idera.com

Editor's Notes

  1. DB_Owner is required for forcing a query plan as well as other administrative commands like flush interval
  2. The unique query plan and query text, if new, will directly be passed to ASYNC Writer which will write it to disk. The query run time statistics will not be directly written to the ASYNC Writer. The query run time statistics will be written at a specific time interval that is set in the Data Flush Interval (Minutes) option.
  3. https://docs.microsoft.com/en-us/sql/relational-databases/system-catalog-views/sys-database-query-store-options-transact-sql?view=sql-server-2017      APPLIES TO: SQL Server (starting with 2016) Azure SQL Database Azure SQL Data Warehouse Parallel Data Warehouse Returns the Query Store options for this database. Applies to: SQL Server ( SQL Server 2016 (13.x) through SQL Server 2017), SQL Database. Column nameData typeDescriptiondesired_statesmallintIndicates the desired operation mode of Query Store, explicitly set by user. 0 = OFF  1 = READ_ONLY 2 = READ_WRITEdesired_state_descnvarchar(60)Textual description of the desired operation mode of Query Store: OFF READ_ONLY READ_WRITEactual_statesmallintIndicates the operation mode of Query Store. In addition to list of desired states required by the user, actual state can be an error state. 0 = OFF  1 = READ_ONLY 2 = READ_WRITE 3 = ERRORactual_state_descnvarchar(60)Textual description of the actual operation mode of Query Store. OFF READ_ONLY READ_WRITE ERROR There are situations when actual state is different from the desired state: - If the database is set to read-only mode or if Query Store size exceeds its configured quota, Query Store may operate in read-only mode even if read-write was specified by the user. - In extreme scenarios Query Store can enter an ERROR state because of internal errors. If this happens, Query Store can be recovered by executing the sp_query_store_consistency_check stored procedure in the affected database.readonly_reasonintWhen the desired_state_desc is READ_WRITE and the actual_state_desc is READ_ONLY, readonly_reason returns a bit map to indicate why the Query Store is in readonly mode. 1 - database is in read-only mode 2 - database is in single-user mode 4 - database is in emergency mode 8 - database is secondary replica (applies to Always On and Azure SQL Database geo-replication). This value can be effectively observed only on readable secondary replicas 65536 - the Query Store has reached the size limit set by the MAX_STORAGE_SIZE_MB option. 131072 - The number of different statements in Query Store has reached the internal memory limit. Consider removing queries that you do not need or upgrading to a higher service tier to enable transferring Query Store to read-write mode. Applies to: Azure SQL Database. 262144 - Size of in-memory items waiting to be persisted on disk has reached the internal memory limit. Query Store will be in read-only mode temporarily until the in-memory items are persisted on disk.  Applies to: Azure SQL Database. 524288 - Database has reached disk size limit. Query Store is part of user database, so if there is no more available space for a database, that means that Query Store cannot grow further anymore. Applies to: Azure SQL Database.  To switch the Query Store operations mode back to read-write, see Verify Query Store is Collecting Query Data Continuously section of Best Practice with the Query Store.current_storage_size_mbbigintSize of Query Store on disk in megabytes.flush_interval_secondsbigintThe period for regular flushing of Query Store data to disk in seconds. Default value is 900 (15 min). Change by using the ALTER DATABASE <database> SET QUERY_STORE (DATA_FLUSH_INTERVAL_SECONDS = <interval>)statement.interval_length_minutesbigintThe statistics aggregation interval in minutes. Arbitrary values are not allowed . Use one of the following: 1, 5, 10, 15, 30, 60, and 1440 minutes. The default value is 60minutes.max_storage_size_mbbigintMaximum disk size for the Query Store in megabytes (MB). Default value is 100 MB. For SQL Database Premium edition, default is 1 GB and for SQL Database Basic edition, default is 10 MB. Change by using the ALTER DATABASE <database> SET QUERY_STORE (MAX_STORAGE_SIZE_MB = <size>)statement.stale_query_threshold_daysbigintNumber of days that queries with no policy settings are kept in Query Store. Default value is 30. Set to 0 to disable the retention policy. For SQL Database Basic edition, default is 7 days. Change by using the ALTER DATABASE <database> SET QUERY_STORE ( CLEANUP_POLICY = ( STALE_QUERY_THRESHOLD_DAYS = <value> ) )statement.max_plans_per_querybigintLimits the maximum number of stored plans. Default value is 200. If the maximum value is reached, Query Store stops capturing new plans for that query. Setting to 0 removes the limitation with regards to the number of captured plans. Change by using the ALTER DATABASE<database> SET QUERY_STORE (MAX_PLANS_PER_QUERY = <n>)statement.query_capture_modesmallintThe currently active query capture mode: 1 = ALL - all queries are captured. This is the default configuration value for SQL Server (SQL Server 2016 (13.x) through SQL Server 2017). 2 = AUTO - capture relevant queries based on execution count and resource consumption. This is the default configuration value for SQL Database. 3 = NONE - stop capturing new queries. Query Store will continue to collect compile and runtime statistics for queries that were captured already. Use this configuration cautiously since you may miss to capture important queries.query_capture_mode_descnvarchar(60)Textual description of the actual capture mode of Query Store: ALL (default for SQL Server 2016 (13.x)) AUTO (default for SQL Database) NONEsize_based_cleanup_modesmallintControls whether cleanup will be automatically activated when total amount of data gets close to maximum size: 0 = OFF - size based cleanup won't be automatically activated. 1 = AUTO - size based cleanup will be automatically activated when size on disk reaches 90 percent of max_storage_size_mb. This is the default configuration value. Size based cleanup removes the least expensive and oldest queries first. It stops when approximately 80 percent of max_storage_size_mb is reached.size_based_cleanup_mode_descnvarchar(60)Textual description of the actual size-based cleanup mode of Query Store: OFF  AUTO (default)wait_stats_capture_modesmallintControls whether Query Store performs capture of wait statistics:  0 = OFF  1 = ON Applies to: SQL Server 2017 (14.x) through SQL Server 2017.wait_stats_capture_mode_descnvarchar(60)Textual description of the actual wait statistics capture mode:  OFF  ON (default) Applies to: SQL Server 2017 (14.x) through SQL Server 2017.