Slow running query2
How to troubleshoot slow-running queries Tuning database queries can be a multi-faceted endeavor. The following sections discuss common items to examine when you are investigating query performance. Note If you are using SQL Server 2005, use SQL Server Management Studio instead of SQL Query Analyzer, and use Database Engine Tuning Advisor instead of the Index Tuning Wizard. Verify the Existence of the Correct Indexes One of the first checks to perform when you are experiencing slow query execution times is an index analysis. If you are investigating a single query, you can use the Perform Index Analysis option in SQL Query Analyzer; if you have a SQL Profiler trace of a large workload, you can use the Index Tuning Wizard. Both methods use the SQL Server query optimizer to determine which indexes would be helpful for the specified queries. This is a very efficient method for determining whether the correct indexes exist in your database. For information about how t...