July 15, 2010 at 8:05 pm
Hi,
1) What is execution plan how it can be used in tunning queries. with the output how can we come to conclusion that query is better by comparing.
I came accross one article it has a eg but i was not able to get
SELECT oh.CustomerID, SUM(LineTotal)
FROM Sales.SalesOrderDetail od JOIN Sales.SalesOrderHeader oh
ON od.SalesOrderID=oh.SalesOrderID
GROUP BY oh.CustomerID
in this what is performance is doing i cant get. i have attached screen shot of the same.
2) How to use profiler to capture slow running query.
I have run rofiler for 10 min for my page and i click on all pages get,insert,update,del all i have done are there in that profiler trace, until now fine after that what can i get or how can i get which query runs slow (if so it is running slow how can i optimize what analyse i have to do how to do). in profiler i used SQL:BatchCompleted ,SQL:Batchstarting,RPC:Completed etc..
3) set statistics io on ,set statistics time on in that what we can get how to come to conclusion
Regards
😀 Parthi :smooooth:
Thanks
Parthi
July 15, 2010 at 10:38 pm
This is quite a big topic and people have written whole books on it. I can give you a link of books which have the anwers to your questions in details
SQL Server Execution Plans - Grant Fritchey
http://www.sqlservercentral.com/articles/books/65831/
Mastering SQL Server Profiler - Brad McGehee
http://www.sqlservercentral.com/articles/books/65797/
How to post data/code on a forum to get the best help - Jeff Moden
http://www.sqlservercentral.com/articles/Best+Practices/61537/
July 15, 2010 at 10:52 pm
Kingston recommended a very good resource. I would also recommend the same book.
Jason...AKA CirqueDeSQLeil
_______________________________________________
I have given a name to my pain...MCM SQL Server, MVP
SQL RNNR
Posting Performance Based Questions - Gail Shaw[/url]
Learn Extended Events
July 16, 2010 at 2:34 am
Also maybe of interest:
Gail Shaw
Microsoft Certified Master: SQL Server, MVP, M.Sc (Comp Sci)
SQL In The Wild: Discussions on DB performance with occasional diversions into recoverability
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply