SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


Which Event Classes i should use for finding good indexs ,statistics and etc to optimise queries and...


Which Event Classes i should use for finding good indexs ,statistics and etc to optimise queries and SPs.

Author
Message
rajemessage 14195
rajemessage 14195
SSC Veteran
SSC Veteran (276 reputation)SSC Veteran (276 reputation)SSC Veteran (276 reputation)SSC Veteran (276 reputation)SSC Veteran (276 reputation)SSC Veteran (276 reputation)SSC Veteran (276 reputation)SSC Veteran (276 reputation)

Group: General Forum Members
Points: 276 Visits: 348
Dear all,

I am trying to use pro filer to create a trace,so that it can be used as workload in
"Database Engine Tuning Advisor" for optimization of one stored procedure.
latter i am planning to use the tamplet to capture the trace on production server, so that i can get the idea
of exact situation.

Please tel me about the Event classes which i should use in trace.

The stored proc contains three insert queries which insert data into a table variable,

Finally a select query is used on same table variable with one union of the same table variable, to generate a sequence for records based on certain condition of few columns.


There are three cases where i am using the above structure of the SP, so there are three SPS out of three , i want to chose one of them based on their performance.

There are 200 to 450 cols in tables, which i am planning to normalize.
but my question is specific to profiler tamplet in following conditions.
I found there is "Tuning" template avialable ( i will use this one also), but i want to make my own for following conditions and for testing and production server.


1) There is only one table with three inserts which gets into a table variable with a final sequence creation block.

2) There are 15 tables with 45 inserts , which gets into a tabel variable with a final

sequence creation block.

3)

There are 3 tables with 9 inserts , which gets into a table variable with a final
sequence creation block.

In all the above case number of record will be around 5 lacks.

Purpose is optimization of queries in SP

like which Event Classes i should use for finding good indexs ,statistics and ect to optimise queries and SPs.

yours sincerely
GilaMonster
GilaMonster
SSC Guru
SSC Guru (88K reputation)SSC Guru (88K reputation)SSC Guru (88K reputation)SSC Guru (88K reputation)SSC Guru (88K reputation)SSC Guru (88K reputation)SSC Guru (88K reputation)SSC Guru (88K reputation)

Group: General Forum Members
Points: 88821 Visits: 45284
From books online:

To build a recommendation of the optimal set of indexes, indexed views, or partitions for your databases, Database Engine Tuning Advisor requires a workload. A workload consists of a Transact-SQL script or a SQL Server Profiler trace saved to a file or table. If you are using a SQL Server Profiler trace file or table, they must contain Transact-SQL batch or remote procedure call (RPC) event classes, and the Event Class and Text data columns.


That's the only requirements. More columns or events will just bloat the trace file without providing any benefit.

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

We walk in the dark places no others will enter
We stand on the bridge and no one may pass


Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search