use .bak to move database to another server

Posted on 2013-11-02
Medium Priority
Last Modified: 2013-11-02
I used to do this a lot and for some reason it is not working this time.

I have sql server 2012 and I am trying to migrate a database to another machine not on my network.  In previous version, I would have simply backed up the database and restored it on the new instance of sql.  This does not seem to be working.  What is the easiest way to complete this transaction?

Question by:gwarcher
  • 2

Accepted Solution

ShareD_Point earned 2000 total points
ID: 39619243

1. Move the backup file to a folder (say C:\SQLBackup) of the remote Machine
2. Use the below statement to restore the database
      RESTORE DATABASE YourDBName FROM DISK = N'C:\SQLBackup\Demo.bak';

Even after following this approach, if the issue still persists, let us know what is the error you are getting.

Hope this helps

Author Comment

ID: 39619317
the error reads 'the backup set holds a backup of a database other than the existing 'dbase name' database.

If I delete the empty database of the same name it throws multiple errors.

Author Closing Comment

ID: 39619450
worked as a text query, but not using the wizard.

Featured Post

Upgrade your Question Security!

Your question, your audience. Choose who sees your identity—and your question—with question security.

Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Microsoft Access has a limit of 255 columns in a single table; SQL Server allows tables with over 255 columns, but reading that data is not necessarily simple.  The final solution for this task involved creating a custom text parser and then reading…
In this article, we will see two different methods to recover deleted data. The first option will be using the transaction log to identify the operation and restore it in a specified section of the transaction log. The second option is simpler and c…
Using examples as well as descriptions, and references to Books Online, show the different Recovery Models available in SQL Server and explain, as well as show how full, differential and transaction log backups are performed
Viewers will learn how to use the INSERT statement to insert data into their tables. It will also introduce the NULL statement, to show them what happens when no value is giving for any given column.

607 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question