Click here to Skip to main content
15,920,633 members
Please Sign up or sign in to vote.
0.00/5 (No votes)
How to analyze sql query & improve its performance.
Is it possible using SSMS ??
Any tools available??

What I have tried:

just checked in SSMS but couldnt find any.
Posted
Updated 6-Apr-16 23:33pm
Comments
CHill60 7-Apr-16 4:06am    
Did you try checking in Google?
Member 11712753 7-Apr-16 4:17am    
You can tell SSMS to include actual "Execution Plan" for your query such that you'll know which part is the bottleneck of your query.

1 solution

There is a plethora of tools available, but the ones I use mostly are:

SQL Server Profiler, see tutorial here: SQL Server Profiler Step by Step[^]

But I would not recommend it, it's too complex and version specific, the open-source ExpressProfiler is much easier to use, see: ExpressProfiler - Home[^]

You can also test queries in SQL Server Management Studio like this:
SET STATISTICS IO ON
SET STATISTICS TIME ON
CHECKPOINT
DBCC DROPCLEANBUFFERS

USE [XXX]

SELECT * FROM MyTable

As already mentioned by Member 11712753, you can use execution plan:
In Management Studio query editor, you can choose to either display an estimated execution plan or the actual execution plan by clicking the Display Estimated Execution Plan or the Include Actual Execution Plan button on the query editor toolbar.
Displaying Graphical Execution Plans (SQL Server Management Studio)[^]
 
Share this answer
 
v2

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900