Friday 27 September 2013

What is in Backup file

There is situation where we have a DB Backup file but not able to determine 
1.       Which Backup exists in Backup file whether it is full, Differential or log.
2.       How to identify logical name of data and log file
So identify it we can use below commands 
Restore headeronly :  
e.g Backup headeronly DBNAME from Disk = ‘Path where backup file’
                Result provide the info like Backup type, 1 for full ,2 for log, 5 for Differential
Or use BackupTypeDiscription column to check it
Also it provides the info like DB name , Server name, LSN info, Recovery model 
Restore Filelistonly
It provide the logical name , physical name of DB Backup file.
e.g Backup filelistonly  DBNAME from Disk = ‘Path where backup file’
It really helps when you are restoring multiple backup like full backup and sequence of log backup.
If any log backup sequence is not getting identify by file name you can identify by LSN sequence

No comments:

Post a Comment