Hi, Is that anyway can we find out in SQL Server 2008 which Stored Procedure are used or has been called from application for last 3 months? Basically I want to remove unused Stored procedure from Database. Thanks
As Shawn points out, there is no way to do this retroactively, but you can set up systems like a Server Side Trace to log it going forward. Any such logging system is going to add some overhead though, especially if you leave it wide open instead of carefully limted. Combing through the transaction logs if you are in full recovery mode would give you vast amounts of information, but even with 3rd party tools to help, they are not exactly a user friendly way to get the answers you are looking for. Some more limited information about what has happened in the past can be gleaned from some of the system views and DMVs like `sys.dm_db_index_usage_stats`. The `sys.dm_exec_procedure_stats` is probably closest to what you are looking for, but not exactly.