Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 help on how to recording run time on these SPs.

Author  Topic 

NguyenL71
Posting Yak Master

228 Posts

Posted - 2008-08-05 : 13:46:05

Hi,

I have the following SPs needs to schedule run every 15 Min for the next 7 days. I need
to collect the respond time and insert them into tables/files for further analysis.
Does anyone has experience on this kind of tasks before?. Or if you know there some tools which
may be able to help me obtain such results. Your suggestions/recommendations are greatly appreciate.

SPs:

EP_SP_ODS_Claim_Export
EP_SP_PM160_Claim_Header_Updates
EP_SP_PM160_Claim_Total_PayStatus_Validations_Updates
EP_SP_PM160_GET_QNXTPROVIDERS
EP_SP_PM160_MEMBER_SEARCH
EP_SP_PM160_REPORT_MONTHLY

rmiao
Master Smack Fu Yak Hacker

7266 Posts

Posted - 2008-08-06 : 23:21:37
You can add something like following in each sp:

insert table(name, start) values ('sp_name', getdate())
....
whatever code in the sp
....
insert table(name, end) values ('sp_name', getdate())
Go to Top of Page

Bustaz Kool
Master Smack Fu Yak Hacker

1834 Posts

Posted - 2008-08-11 : 19:18:53
One thing that we have done is to run Profiler (from a different server), filter for the SPs in question, make sure that the begin and end times are included in your Profile session and then write the results to a table (again, using a server different from the server being profiled).

Now you can analyze things at your leisure.

=======================================
Some people walk in the rain, others just get wet. -Roger Miller, musician (1936-1992)
Go to Top of Page
   

- Advertisement -