Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

Difference between RPC:Completed and SP:Completed

956 views
Skip to first unread message

peja

unread,
Feb 4, 2006, 11:17:34 AM2/4/06
to
Hi,
I know that SP refers to stored procedures, and RPC to remote procedure
calls, but I don't know what that means in real life.
I can see in my trace files that each stored procedure has related
RPC:Completed event. So why would anybody include SP:Completed event too?
Any ideas or advices?
Thanks


Andrew J. Kelly

unread,
Feb 4, 2006, 11:35:18 AM2/4/06
to
SP:Completed events would occur if you called a sp from within another sp or
if the sp was initially called in a batch. If you only traced RPC events
you would miss these executions. Sometimes you don't care to see anything
other than the initial call to the server which would either be a RPC or a
batch depending on how the call was made. An RPC only occurs when you call
the sp as a sp. By that I mean you would use the command type of stored
procedure to properly execute a sp as a RPC. If you said the type was text
it would come across as a Batch:Completed and then it would have a
SP:Completed. This is due to the fact each batch gets a plan and each sp
execution gets it's own plan as well. Note that not all columns show up for
SP:Completed as they do for RPC and Batch such as reads, cpu etc.

--
Andrew J. Kelly SQL MVP


"peja" <pe...@sympatico.ca> wrote in message
news:erFcUZa...@TK2MSFTNGP11.phx.gbl...

0 new messages