Prepared SQL and Profiler

  • Good afternoon.  I am trying to tune my production SQL server, but I am running into a challenge.  There is a third-party application that access the database, but it uses mostly prepared SQL calls.  When I run Profiler against this database, there is nothing in the "Text" column nor in the "end time" and "duration" columns.  Therefore, it is hard for me to do anything with the results.  Any ideas?  Thanks.

    Chris

  • This was removed by the editor as SPAM

  • There is a way to get the SQL, but I can't remember it offhand and I don't have access to EM here.  Look under the events that your trace is including.  There *should* be one that is the actual prepare event - which contains the SQL.

  • Thanks, Pam.  I'll take a look.

  • Pam, thanks for your suggestion.  It did allow me to capture the SQL from the execution of the prepared SQL statements.  To my dispair, however, the index tuning wizard had no recommendations, based on the workload used for comparison.  Any ideas?  Thanks.

    Chris

  • Plug the SQL into query analyzer and look at the query plan.

    Post the SQL (and DDL) here and let us take a look.

  • Not looking at one query in particular but all of those captured from an application.  I'll take a closer look and let you guys know if I have any further questions.  Thanks again.

    Chris

  • Then your first step is to identify which of those queries are the worst-performing ones.  Take a look here for some hints onthat:

    http://www.sql-server-performance.com/sql_server_performance_audit10.asp

Viewing 8 posts - 1 through 7 (of 7 total)

You must be logged in to reply to this topic. Login to reply