We starting to get a lot of stored procedures in our application. Many of them are for custom reports many of which are no longer used. Does anyone know of a query we could run on the system views in SQL Server 2005 that would tell us the last date a stored procedure was executed?
Sql-server – Last Run Date on a Stored Procedure in SQL Server
sql server
Related Topic
- Sql-server – How to check if a column exists in a SQL Server table
- Sql – How to concatenate text from multiple rows into a single text string in SQL Server
- Sql-server – LEFT JOIN vs. LEFT OUTER JOIN in SQL Server
- Sql – Insert results of a stored procedure into a temporary table
- Sql-server – the best way to auto-generate INSERT statements for a SQL Server table
- Sql – Function vs. Stored Procedure in SQL Server
- Sql – How to UPDATE from a SELECT in SQL Server
- Sql – Search text in stored procedure in SQL Server
Best Answer
The below code should do the trick (>= 2008)
Edit 1 : Please take note of Jeff Modens advice below. If you find a procedure here, you can be sure that it is accurate. If you do not then you just don't know - you cannot conclude it is not running.