O'Reilly logo

SQL Server DMVs in Action: Better Queries with Dynamic Management Views by Ian W. Stirk

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Chapter 11. Useful scripts

 

This chapter covers
  • Viewing everyone’s last-run SQL query
  • A generic performance test harness
  • Estimating the finishing time of jobs
  • Finding where your query really spends its time
  • A simple lightweight tracing utility

 

Gallimaufry refers to “odds and ends,” and that nicely sums up the content of this chapter. It contains a hodgepodge of scripts that can reveal some interesting and useful information. The scripts given in this chapter wouldn’t sit comfortably within the other chapters of the book.

The content of this chapter is wide ranging, covering such diverse areas as finding which SQL queries everyone last ran, getting Windows system information within SQL Server, determining where your queries really ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required