Reputation: 1384
I am interested in profiling SQL Server database transactions that are being executed by a java application.
Particularly I am interested in finding out what queries (query strings) get executed as a part of the transaction.
Database I am using is SQL Server 2008.
Right now I am selecting Exec Prepared SQL
event and Prepare SQL
event in the profiler but that does not give me the query strings that are being executed by the application. I see a bunch of exec
statements but nothing more. It doesn't have details as to what query was being executed.
Would anyone have an idea of how can I get access to the query strings?
Regards,
Upvotes: 1
Views: 4867
Reputation: 27904
My typicals are:
RPC:Completed.
SP Completed.
SP:StmtCompleted
Exec Prepared SQL
SQL : BatchCompleted
SQL : StmtCompleted
And I pick the TextData columnn (and some others).
Do you know about DMV queries?
Upvotes: 3