Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

SQL Server 2005 Profiler How do you view the entire Stored Procedure Chain

SQL Server 2005 Profiler shows that a Stored Procedure (SP) was called and what variables were passed. However I don't know how to get profiler to show me subsequent calls. By this I mean when SP A calls SP B and SP B calls SP C.

Is there a way to get profiler to show this chain?

Thanks

like image 356
codingguy3000 Avatar asked Aug 18 '09 23:08

codingguy3000


People also ask

How do I view SQL profiler traces?

To open the trace file: Open SQL Profiler, Start > Programs > Microsoft SQL Server > Profiler. Select File > Open >Trace File. Navigate to the directory where the trace file was stored and open it.

How do you trace the traffic hitting a SQL Server?

How do you trace the traffic hitting a SQL Server? Example: "You use SQL profiler to trace the traffic on the SQL Server instance. To narrow down the transactions that are captured, you can use a filter. The trace files can be searched, saved or even replayed to help with troubleshooting."


1 Answers

You can enable the SP:StmtCompleted event to see each statement inside the procedures, insluding calls to other procedures. Note that this is quite heavy tracing, should be used exclusively for debugging purposes, not on live servers.

like image 66
Remus Rusanu Avatar answered Oct 13 '22 19:10

Remus Rusanu