Table of Contents

 

Copyright

Brief Table of Contents

Table of Contents

Preface

Acknowledgements

About this Book

1. Starting the journey

Chapter 1. The Dynamic Management Views gold mine

1.1. What are Dynamic Management Views?

1.1.1. A glimpse into SQL Server’s internal data

1.1.2. Aggregated results

1.1.3. Impact of running DMVs

1.1.4. Part of SQL Server 2005 onward

1.2. The problems DMVs can solve

1.2.1. Diagnosing problems

1.2.2. Performance tuning

1.2.3. Monitoring

1.3. DMV examples

1.3.1. Find your slowest queries

1.3.2. Find those missing indexes

1.3.3. Identify what SQL statements are running now

1.3.4. Quickly find a cached plan

1.4. Preparing to use DMVs

1.4.1. Permissions

1.4.2. Clearing DMVs

1.5. DMV companions

1.5.1. Catalog views

1.5.2. Cached plans

1.5.3. Indexes

1.5.4. Statistics

1.6. Working with DMVs

1.6.1. In context with other tools

1.6.2. Self-healing database

1.6.3. Reporting and transactional databases

1.7. Summary

Chapter 2. Common patterns

2.1. Reducing blocking

2.2. Using CROSS APPLY

2.3. Restricting output to a given database

2.4. Restricting output by using the TOP command

2.5. Creating an empty temporary table structure

2.6. Looping over the databases on a server

2.7. Retrieving a query’s cached plan and SQL text

2.8. Extracting the Individual Query from the Parent Query