April 29, 2008 at 2:49 am
Hi,
How can we know when did a stored procedure was executed
April 29, 2008 at 7:25 am
[font="Courier New"]I hope this details won't be stored in any of the systables.. Hope you need to run profiler or you can create some trigger to update user table for the execution date!![/font]
Regards..Vidhya Sagar
SQL-Articles
May 1, 2008 at 1:50 pm
Are you trying to find out whether a proc has been run recently?
If not, you can always modify the proc to log it's most recent run-date in a table.
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
May 1, 2008 at 6:36 pm
What's wrong with using the Profiler?
--Jeff Moden
Change is inevitable... Change for the better is not.
May 2, 2008 at 9:15 am
If it's not running, or wasn't running at the last time the proc was run, it doesn't get you what you need.
- Gus "GSquared", RSVP, OODA, MAP, NMVP, FAQ, SAT, SQL, DNA, RNA, UOI, IOU, AM, PM, AD, BC, BCE, USA, UN, CF, ROFL, LOL, ETC
Property of The Thread
"Nobody knows the age of the human race, but everyone agrees it's old enough to know better." - Anon
May 2, 2008 at 7:16 pm
So, turn it on... end of proc trace takes no overhead and beats the heck out of modifying 300+ procs 🙂
--Jeff Moden
Change is inevitable... Change for the better is not.
May 16, 2008 at 8:06 am
I don't want to use profiler or else lets say I am in PROD ENV and no profiler is available then? Of course u can you implement some BL to find it out when was it last executed. But i just want to whether SQL Server has any inbuilt mechanism
Viewing 7 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic. Login to reply