September 6, 2012 at 5:36 am
Hi
I am wondering for; Will SQL Profiler will capture trace for the hard coded
query in application.
Answers will be thankfull.
Ali
MCTS SQL Server2k8
September 6, 2012 at 6:07 am
Ali Tailor (9/6/2012)
HiI am wondering for; Will SQL Profiler will capture trace for the hard coded
query in application.
Answers will be thankfull.
a profiler session or a server side trace can catch all commands hitting the server, regardless of the source/application that is calling them.
The events I typically capture are SQL:BatchCompleted, which is SQL commands and RPC:Completed , which are calls to execute stored procedures.
this is a decent server side DML trace model I put together, if you think it can help:
Lowell
September 6, 2012 at 7:12 am
M
Lowell (9/6/2012)
Ali Tailor (9/6/2012)
HiI am wondering for; Will SQL Profiler will capture trace for the hard coded
query in application.
Answers will be thankfull.
a profiler session or a server side trace can catch all commands hitting the server, regardless of the source/application that is calling them.
The events I typically capture are SQL:BatchCompleted, which is SQL commands and RPC:Completed , which are calls to execute stored procedures.
this is a decent server side DML trace model I put together, if you think it can help
Thank you very much Lowell for you prompt & Detail reply.
Thanks a lot for attached script.
Ali
MCTS SQL Server2k8
September 6, 2012 at 7:23 am
glad I could help Ali;
pay attention to the code at the bottom, which is creating a VIEW named sp_MyTrace so you can query the trace any time, with a simple query:
little details like that makes working with traces incredibly easy.
SELECT * FROM sp_MyTrace
Lowell
Viewing 4 posts - 1 through 3 (of 3 total)
You must be logged in to reply to this topic. Login to reply