Friday, March 30, 2012

Help!!

Hi,
I'm new to SQL Server. One of our databases is very slow. Need to look into it. Any ideas?
Thanks!!Run some of your frequently used queries though the query analyser and look at the execution plan. This will give you a break down of how much time is being used in each step of the query and should give an indication of where you should start looking to improve performance.|||Start with the profiler! Check for

- long running queries
- locks and the duration thereof
- scans

Then you can start using the Query Analyzer. Add (nolock) where appropriate, index your tables and if you have ANY in-line SQL with variable where statements or more than one table then you should immediately move those to stored procedures.|||As rokslide said.. you can check the Execution Plan.. but.. if you have done it.. first you must create all the indexes and the primary keys in your tables.

No comments:

Post a Comment