Solved

SQL EXPRESS and SQL Server backup and restore issue smo

Posted on 2007-11-22
5
1,676 Views
Last Modified: 2008-02-01
Hello Tech Gurus,

I took a backup of my database in SQL EXPRESS( using the backup option when when right click on the database)  and now i trying to restore this database in proper SQL SERVER( restore option we get when you right click on the database folder) and it won't. It says " Restore failed for "SERVER_NAME" Microsoft.Sql.Server.smo"
Restore failed for Server 'PURPLESERV'.  (Microsoft.SqlServer.Smo)

Following is the detailed error message

System.Data.SqlClient.SqlError: The backup set holds a backup of a database other than the existing 'StandardTimeSQL' database. (Microsoft.SqlServer.Smo)

------------------------------
Program Location:

   at Microsoft.SqlServer.Management.Smo.Restore.SqlRestore(Server srv)
   at Microsoft.SqlServer.Management.SqlManagerUI.SqlRestoreDatabaseOptions.RunRestore()

===================================

System.Data.SqlClient.SqlError: The backup set holds a backup of a database other than the existing 'StandardTimeSQL' database. (Microsoft.SqlServer.Smo)

------------------------------
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=9.00.1399.00&LinkId=20476

------------------------------
Program Location:

   at Microsoft.SqlServer.Management.Smo.ExecutionManager.ExecuteNonQueryWithMessage(StringCollection queries, ServerMessageEventHandler dbccMessageHandler, Boolean errorsAsMessages)
   at Microsoft.SqlServer.Management.Smo.BackupRestoreBase.ExecuteSql(Server server, StringCollection queries)
   at Microsoft.SqlServer.Management.Smo.Restore.SqlRestore(Server srv)


Thanking you in Advance
Regards

0
Comment
Question by:Danbrasco
  • 3
  • 2
5 Comments
 
LVL 25

Accepted Solution

by:
imitchie earned 500 total points
ID: 20333948
include the WITH REPLACE command
0
 
LVL 25

Assisted Solution

by:imitchie
imitchie earned 500 total points
ID: 20333955
or from the gui, go to the 2nd tab and tick overwrite
0
 

Author Comment

by:Danbrasco
ID: 20334171
I think i have select this radio button option and manage to restore but it seems to be empty. How can i check if it has been restored.
0
 

Author Comment

by:Danbrasco
ID: 20334229
After restoring the database into SQL server, I tried creating the  same users again( that use to be in the SQL EXPRESS ) but it says that user already exsit but i don't have users listed in the login list.
Please see the following error

Server Name: SEVER_NAME
Error Number: 15023
Severity: 16
State: 1
Line Number: 1

User, group, or role 'MY_NAME' already exists in the current database. (.Net SqlClient Data Provider)
0
 
LVL 25

Assisted Solution

by:imitchie
imitchie earned 500 total points
ID: 20336046
try

sp_dropuser username

before adding again
0

Featured Post

NAS Cloud Backup Strategies

This article explains backup scenarios when using network storage. We review the so-called “3-2-1 strategy” and summarize the methods you can use to send NAS data to the cloud

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Recently, when I was asked to create a new SQL 2005 cluster, Microsoft released a new service pack for MS SQL 2005 what is Service Pack 3. When I finished the installation of MS SQL 2005 I found myself troubled why the installation of SP3 failed …
Introduction: When running hybrid database environments, you often need to query some data from a remote db of any type, while being connected to your MS SQL Server database. Problems start when you try to combine that with some "user input" pass…
Microsoft Active Directory, the widely used IT infrastructure, is known for its high risk of credential theft. The best way to test your Active Directory’s vulnerabilities to pass-the-ticket, pass-the-hash, privilege escalation, and malware attacks …

820 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