Skip to Main Content
Learn T-SQL Querying
book

Learn T-SQL Querying

by Pedro Lopes, Pam Lahoud
May 2019
Intermediate to advanced content levelIntermediate to advanced
484 pages
11h 23m
English
Packt Publishing
Content preview from Learn T-SQL Querying

The query_plan_profile XEvent

SQL Server 2016 SP2 CU3 and SQL Server 2017 CU11 introduced a new XEvent named query_plan_profile. This XEvent outputs the equivalent of a query execution plan such as the query_post_execution_showplan XEvent. Unlike the query_post_execution_showplan XEvent, which uses Standard Profiling, query_plan_profile uses lightweight profiling by default.

The query_plan_profile XEvent allows a very targeted plan collection that can be used for a longer period of time to gather data for a specific query execution and doesn't require any object or statement filtering in the XEvent session. This is because the XEvent only fires for a query or queries that are using the USE HINT ('QUERY_PLAN_PROFILE') hint.

The following is ...

Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Learn T-SQL Querying - Second Edition

Learn T-SQL Querying - Second Edition

Pedro Lopes, Pam Lahoud
SQL Server T-SQL Recipes, Fourth Edition

SQL Server T-SQL Recipes, Fourth Edition

Jason Brimhall, Jonathan Gennick, Wayne Sheffield

Publisher Resources

ISBN: 9781789348811Supplemental Content