未加星标

SQL Server 2016 Query Store - Gentle Introduction - 1

字体大小 | |
[数据库(mssql) 所属分类 数据库(mssql) | 发布者 店小二05 | 时间 2016 | 作者 红领巾 ] 0人收藏点击收藏

SQL Server 2016 Query Store - Gentle Introduction - 1
SQL and SQL Only

I am Nagaraj (aka Raj), a SQL Server Database Administrator for one of the busiest OLTP systems in Singapore. Being a SQL Enthusiast for over 10 years now, I love to explore and share more and more on SQL Server.

SQL Server 2016 Query Store - Gentle Introduction - 1 Posted on 9 October 2016 Comments

Query Store is perhaps one of the path breaking features to release in SQL Server 2016. This post will give a quick introduction to the same.


What is this query store?
Short answer: Records / Stores every query plan generated along with theirrun timestatistics like Execution Count, Row count, Execution cost, IO and memory usage on to the user database.
What are the key benefits?
1) One can track the queryrun timeperformance easily at any point in time

2) Track change of a query plan or change in performance of a particular query over a period of time

3) Track regression - Find which queries started performing badly

4) Query plans will be part of user database backup

5) Ability to force plans via user graphical

interface ( unlike plan guides which demanded some scripting)


What else we get?
4 wonderful reports
1) Regression report -> To track queries that have performed badly over a period of time. One gets to compare historical performance against recent performance
2) Top consuming queries -> To find the poor performing queries by CPU / duration /IO last one hour etc
3) Overall performance report -> Reports average response times, total queries executed etc
4) Tracked queries -> useful to see the trend in performance of a particular query
How to configure?
Right Click on the Database -> Properties -> Query Store -> Set Operation mode to read write.

Rest can be left at default to get it started or you may use the script below

USE [master] GO ALTER DATABASE [DBNAME] SET QUERY_STORE = ON GO ALTER DATABASE [DBNAME] SET QUERY_STORE ( OPERATION_MODE = READ_WRITE , DATA_FLUSH_INTERVAL_SECONDS = 60 , INTERVAL_LENGTH_MINUTES = 1 ) GO
SQL Server 2016 Query Store - Gentle Introduction - 1
SQL Server 2016 Query Store - Gentle Introduction - 1
That's a decent start with query store. Upcoming posts will cover various bells and whistles in it.

本文数据库(mssql)相关术语:熊片数据库 mssql数据库 oracle数据库 pubmed数据库 access数据库 万方数据库

主题: SQLSQL ServerCPURYUTTI
分页:12
转载请注明
本文标题:SQL Server 2016 Query Store - Gentle Introduction - 1
本站链接:http://www.codesec.net/view/481167.html
分享请点击:


1.凡CodeSecTeam转载的文章,均出自其它媒体或其他官网介绍,目的在于传递更多的信息,并不代表本站赞同其观点和其真实性负责;
2.转载的文章仅代表原创作者观点,与本站无关。其原创性以及文中陈述文字和内容未经本站证实,本站对该文以及其中全部或者部分内容、文字的真实性、完整性、及时性,不作出任何保证或承若;
3.如本站转载稿涉及版权等问题,请作者及时联系本站,我们会及时处理。
登录后可拥有收藏文章、关注作者等权限...
技术大类 技术大类 | 数据库(mssql) | 评论(0) | 阅读(27)