Full Database Backups

SELECT database_name, backup_start_date, type, * 
FROM msdb.dbo.backupset
WHERE backup_start_date BETWEEN DATEADD(hh, -24, GETDATE()) AND GETDATE()
AND Type = 'D'
ORDER BY backup_set_id DESC
GO

Transaction Log Backups

SELECT database_name, backup_start_date, type, * 
FROM msdb.dbo.backupset
WHERE backup_start_date BETWEEN DATEADD(hh, -24, GETDATE()) AND GETDATE()
AND Type = 'L'
ORDER BY backup_set_id DESC
GO

Differential Backups

SELECT database_name, backup_start_date, type, * 
FROM msdb.dbo.backupset
WHERE backup_start_date BETWEEN DATEADD(hh, -24, GETDATE()) AND GETDATE()
AND Type = 'I'
ORDER BY backup_set_id DESC
GO

File\File Group Backups

SELECT database_name, backup_start_date, type, * 
FROM msdb.dbo.backupset
WHERE backup_start_date BETWEEN DATEADD(hh, -24, GETDATE()) AND GETDATE()
AND Type = 'F'
ORDER BY backup_set_id DESC
GO
arrow
arrow
    全站熱搜
    創作者介紹
    創作者 kunchung 的頭像
    kunchung

    kunchung的部落格

    kunchung 發表在 痞客邦 留言(0) 人氣()