Home All Groups Group Topic Archive Search About

Profiler - details of SP

Author
19 Oct 2006 9:15 PM
Thomas.LeBlanc@NoSpam.Com
How can I setup Profiler to track/watch the execution of the lines in a
stored procedure?

It looks like I just see exec sp_DoWork, as TextData.

I want to see the sql statements in the SP and how long they each take.
--
Thanks,
ThomasLL

Author
19 Oct 2006 9:43 PM
Kart
Hi,

I am not sure whether this is possible....

But as soon as you have identified the SP thats taking time, why dont
you check the execution plan of that SP instead?



Thomas.LeBlanc@NoSpam.Com wrote:
Show quoteHide quote
> How can I setup Profiler to track/watch the execution of the lines in a
> stored procedure?
>
> It looks like I just see exec sp_DoWork, as TextData.
>
> I want to see the sql statements in the SP and how long they each take.
> --
> Thanks,
> ThomasLL
Are all your drivers up to date? click for free checkup

Author
20 Oct 2006 12:51 AM
Kalen Delaney
Hi Thomas
You can trace SP:StmtStarting and SP:StmtCompleted

--
HTH
Kalen Delaney, SQL Server MVP
http://sqlblog.com


"Thomas.LeBlanc@NoSpam.Com"
<ThomasLeBlancNoSpamCom@discussions.microsoft.com> wrote in message
Show quoteHide quote
news:560746F5-F88B-49A5-9A13-EF873EBDD161@microsoft.com...
> How can I setup Profiler to track/watch the execution of the lines in a
> stored procedure?
>
> It looks like I just see exec sp_DoWork, as TextData.
>
> I want to see the sql statements in the SP and how long they each take.
> --
> Thanks,
> ThomasLL
Author
20 Oct 2006 1:16 PM
Thomas.LeBlanc@NoSpam.Com
That gives me the duration of each Insert, Updaet and Select in the SP?


Thanks Karen, you are a blessing to the SQL Server community

--
Thanks,
Thomas


Show quoteHide quote
"Kalen Delaney" wrote:

> Hi Thomas
> You can trace SP:StmtStarting and SP:StmtCompleted
>
> --
> HTH
> Kalen Delaney, SQL Server MVP
> http://sqlblog.com
>
>
> "Thomas.LeBlanc@NoSpam.Com"
> <ThomasLeBlancNoSpamCom@discussions.microsoft.com> wrote in message
> news:560746F5-F88B-49A5-9A13-EF873EBDD161@microsoft.com...
> > How can I setup Profiler to track/watch the execution of the lines in a
> > stored procedure?
> >
> > It looks like I just see exec sp_DoWork, as TextData.
> >
> > I want to see the sql statements in the SP and how long they each take.
> > --
> > Thanks,
> > ThomasLL
>
>
>
Author
21 Oct 2006 10:02 PM
Kalen Delaney
SP:StmtCompleted can give you the duration of each statement in the SP.

Thanks for your kind words. Karen thanks you too. ;-)

--
HTH
Kalen Delaney, SQL Server MVP
http://sqlblog.com


"Thomas.LeBlanc@NoSpam.Com"
<ThomasLeBlancNoSpamCom@discussions.microsoft.com> wrote in message
Show quoteHide quote
news:CC7D6F54-4DE7-4DE8-B7CC-7904572FDF90@microsoft.com...
> That gives me the duration of each Insert, Updaet and Select in the SP?
>
>
> Thanks Karen, you are a blessing to the SQL Server community
>
> --
> Thanks,
> Thomas
>
>
> "Kalen Delaney" wrote:
>
>> Hi Thomas
>> You can trace SP:StmtStarting and SP:StmtCompleted
>>
>> --
>> HTH
>> Kalen Delaney, SQL Server MVP
>> http://sqlblog.com
>>
>>
>> "Thomas.LeBlanc@NoSpam.Com"
>> <ThomasLeBlancNoSpamCom@discussions.microsoft.com> wrote in message
>> news:560746F5-F88B-49A5-9A13-EF873EBDD161@microsoft.com...
>> > How can I setup Profiler to track/watch the execution of the lines in a
>> > stored procedure?
>> >
>> > It looks like I just see exec sp_DoWork, as TextData.
>> >
>> > I want to see the sql statements in the SP and how long they each take.
>> > --
>> > Thanks,
>> > ThomasLL
>>
>>
>>

Bookmark and Share

Post Thread options