How to find database restore history from MSDB?


MSDB database is used by SQL Server Agent for scheduling alerts and jobs and by other features such as Service Broker and Database Mail. Again SQL Server is using MSDB for storing the history of backup, restore, log-shipping details and more…

You can query the MSDB as below to get the details about the SQL Server restore history.

SELECT TOP 10 *
FROM restorehistory WITH (nolock)WHERE (destination_database_name = 'Database Name')ORDER BY restore_date DESC
All Databases

SELECT TOP 10 * FROM restorehistory WITH (nolock)ORDER BY restore_date DESC

3 thoughts on “How to find database restore history from MSDB?

  1. Neeraj Kumar's avatarNeeraj Kumar

    Thanks Jugal,
    I am able to find the restore history now….please again do me a favor.. i want to find who and when delete operation is performed….can we find the same for truncate??

    Reply
      1. Neeraj Kumar's avatarNeeraj Kumar

        I am using CDC for delete…but i am not able to find the user who deleted the record..how can we find??

Thanks for the comment, will get back to you soon... Jugal Shah