SQL Server: how to query when the last transaction log backup has been taken? -


I want to query all the databases (in the instance of SQL Server 2008) when the last transaction log was backed up is. How to do it I know that this information is somewhere, but I do not know where it is.

  select D.name, MAX (b.backup_finish_date) s backup_finish_date to master.sys. Sysdatabases D to LEFT OUTER JOIN msdb.backupset b ON b.database_name = d.name and b.type = 'l' group by d.name command backup_finish_date DESC  

Comments