1

I've been using SQL Server 2012 for as long as I can remember. When I do a backup it's always saved as .bak file format. However, there's this other server that has SQL Server 2012 and when I do a backup, it's not saved as .bak but just a generic 'file' file format. When I try to restore this file it works just fine. I'd just like to know why it didn't save as .bak file. In other servers that I've worked on it's always .bak. Thank you so much.

enter image description here

asked Aug 8, 2019 at 3:05

2 Answers 2

5

Take a look at the command that is generating the backups (it could be a job, a maintenance plan, 3rd party tool, etc.).

You can give the file any extension you like, including no extension. Windows Explorer might not know what on earth it is, but SQL Server will still be able to restore it just fine.

answered Aug 8, 2019 at 3:29
2

I'd just like to know why it didn't save as .bak file. In other servers that I've worked on it's always .bak

This might have happened:

Declare @BackupPath varchar (256),
 @DBName varchar (256),
 @DateTime varchar (25)
--- With Extension (Other Server)
set @BackupPath = '\\SharedLocation\' + @DBName + '_Full_' + @Datetime + '.bak';
--- Without Extension 
set @BackupPath = '\\SharedLocation\' + @DBName + '_Full_' + @Datetime;

or you might have missed to type .bak if the backup was created manually via SSMS.

However, as mentioned by @AaronBertrand there would no issue during restore with the backup that created without extension.

answered Aug 8, 2019 at 9:35

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.