Microsoft SQL Server 2017 on Linux by Benjamin Nevarez

Microsoft SQL Server 2017 on Linux by Benjamin Nevarez

Author:Benjamin Nevarez
Language: eng
Format: epub
Publisher: McGraw-Hill Education
Published: 2018-03-04T16:00:00+00:00


Examine the output. Because the number of columns is too large to show in this book, only some of the columns are shown next:

As you can see by looking at the query text, all three queries were compiled as part of the same batch, which we can also verify by validating they have the same plan_handle and sql_handle. The statement_start_offset and statement_end_offset values can be used to identify the particular queries in the batch, a process that will be explained later in this section. You can also see in this output the number of times the query was executed and several columns showing the CPU time used by each query, as total_worker_time, last_worker_time, min_worker_time, and max_worker_time. Should the query be executed more than once, the statistics would show the accumulated CPU time on total_worker_time. Additional performance statistics for physical reads, logical writes, logical reads, CLR time, and elapsed time are also displayed in the previous query but not shown in the book for page space. You can look at the SQL Server documentation online for the entire list of columns, including performance statistics and their documented descriptions.

Keep in mind that this view shows statistics for completed query executions only. You can look at sys.dm_exec_requests for information about queries currently executing. Finally, remember that certain types of execution plans may never be cached, and some cached plans may also be removed from the plan cache for several reasons, including internal or external memory pressure on the plan cache. Information for these plans would therefore not be available on sys.dm_exec_query_stats. Let’s now take a look at the statement_start_offset and statement_end_offset values.



Download



Copyright Disclaimer:
This site does not store any files on its server. We only index and link to content provided by other sites. Please contact the content providers to delete copyright contents if any and email us, we'll remove relevant links or contents immediately.