SQL Server database restore error specified cast is not valid SqlManagerUI

0 votes

For my production website, SQL Server 2008 R2 Standard (version 10.50.1600.1), and for my localhost database, SQL Server Express edition with Advanced Services (version 10.50.1600.1).

A few days ago, my SQL Server crashed, necessitating the installation of a fresh 2008 R2 Express copy on my localhost. The prior versions I restored from the Express edition worked just fine, but when I try to restore the database from the production server's.bak file, I get the following error:

Error: Specified cast is not valid. (SqlManagerUI)

When I try to restore the database using the command:

Use Master
Go
RESTORE DATABASE Publications
FROM DISK = 'C:\Publications.bak'
WITH MOVE 'Publications' TO 'C:\Program Files\Microsoft SQL Server\MSSQL10_50.SQLEXPRESS2008R2\MSSQL\DATA\Publications.mdf',--adjust path
MOVE 'AlPublications_log' TO 'C:\Program Files\Microsoft SQL Server\MSSQL10_50.SQLEXPRESS2008R2\MSSQL\DATA\Publications.ldf'

This makes different errors:

Msg 3154, Level 16, State 4, Line 1
The backup set holds a backup of a database other than the existing 'Publications' database.
Msg 3013, Level 16, State 1, Line 1
RESTORE DATABASE is terminating abnormally.

The versions have all been cross-checked. I think they all match, as evidenced by the picture below. Prior to today, I could successfully restore a database from the standard edition to the express edition. I attempted to reconstruct the database after deleting it. That also fails.

I'm unsure of what I'm doing incorrectly. Regarding, I would appreciate the assistance. As it appeared, the problem was solved. The backup file was damaged. It worked when I tried it with a different file. 

Can someone please help me with this?

Aug 20 in Database by Kithuzzz
• 11,640 points
59 views

No answer to this question. Be the first to respond.

Your answer

Your name to display (optional):
Privacy: Your email address will only be used for sending these notifications.

Related Questions In Database

0 votes
1 answer

Login failed for user 'sa'. The user is not associated with a trusted SQL Server connection. (Microsoft SQL Server, Error: 18452) in sql 2008

Solution Go to Start > Programs > Microsoft SQL Server > Enterprise Manager. Right-click the SQL ...READ MORE

answered Sep 12 in Database by narikkadan
• 19,680 points
34 views
0 votes
0 answers

Why is SQL Server Agent not starting?

On top of Windows Server 2012, I ...READ MORE

Aug 9 in Database by Kithuzzz
• 11,640 points
17 views
0 votes
0 answers
0 votes
1 answer

Rename column SQL Server 2008

Use sp_rename EXEC sp_RENAME 'TableName.PreviousColumnName' , 'NewColumnName', 'COLUMN' See: SQL SERVER ...READ MORE

answered Feb 23 in Database by Vaani
• 7,020 points
49 views
0 votes
0 answers

How to change column datatype in SQL database without losing data?

I have a SQL Server database, and ...READ MORE

Feb 25 in Database by Vaani
• 7,020 points
91 views
0 votes
0 answers

How to update Identity Column in SQL Server?

With 200 records currently, I want to ...READ MORE

Aug 9 in Database by Kithuzzz
• 11,640 points
159 views
0 votes
0 answers

What is the difference between drop table and delete table in SQL Server?

What is the distinction between the following ...READ MORE

Aug 9 in Database by Kithuzzz
• 11,640 points
63 views
webinar REGISTER FOR FREE WEBINAR X
Send OTP
REGISTER NOW
webinar_success Thank you for registering Join Edureka Meetup community for 100+ Free Webinars each month JOIN MEETUP GROUP