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.
| Author |
Topic |
|
stonebreaker
Yak Posting Veteran
92 Posts |
Posted - 2008-01-21 : 11:47:30
|
| Is there someplace in the database I could check to see when the last time a stored proc was altered?Thanks in advance. |
|
|
sodeep
Master Smack Fu Yak Hacker
7174 Posts |
Posted - 2008-01-21 : 12:56:41
|
| Maybe this helps.If stored procedure was created but never modified afterwards modified date and create date for that stored procedure are same.SELECT nameFROM sys.objectsWHERE type = 'P'AND DATEDIFF(D,modify_date, GETDATE()) < 7 --Change 7 to any other day value.Following script will provide name of all the stored procedure which were created in last 7 days, they may or may not be modified after that.SELECT nameFROM sys.objectsWHERE type = 'P'AND DATEDIFF(D,create_date, GETDATE()) < 7 --Change 7 to any other day value |
 |
|
|
stonebreaker
Yak Posting Veteran
92 Posts |
Posted - 2008-01-21 : 13:49:46
|
| Exactly what I needed, thank you very much! |
 |
|
|
|
|
|