July 10, 2008 at 12:25 pm
I have a Windows 2000 Server with SQL 2000 32 in product. Trying to implement a new server all 64 bit SQL and O/S enterprise.
I can not seem to restore the DB to the new server. I am using the SQL backup untility
What can be the issue
Andy
July 10, 2008 at 12:34 pm
Are you getting an error? What do you mean by ' can not seem to restore the DB to the new server'?
July 10, 2008 at 12:39 pm
Here is the error code
ITLE: Microsoft SQL Server Management Studio
------------------------------
Restore failed for Server 'PARKING01'. (Microsoft.SqlServer.Smo)
------------------------------
ADDITIONAL INFORMATION:
An exception occurred while executing a Transact-SQL statement or batch. (Microsoft.SqlServer.ConnectionInfo)
------------------------------
The backup set holds a backup of a database other than the existing 'Shelter' database.
RESTORE LOG is terminating abnormally. (Microsoft SQL Server, Error: 3154)
For help, click: http://go.microsoft.com/fwlink?ProdName=Microsoft+SQL+Server&ProdVer=09.00.1406&EvtSrc=MSSQLServer&EvtID=3154&LinkId=20476
------------------------------
BUTTONS:
OK
------------------------------
July 10, 2008 at 12:50 pm
It sounds like a database of the same name is on the new server - if that is the case, use With Replace.
July 10, 2008 at 1:08 pm
So did you already create a database by that name on your destination server? If so, you'll need to do as Peter suggests and use WITH REPLACE. You may also need to use the MOVE command to specify the new data/log files.
**Be careful with the REPLACE command as it will overwrite the existing DB!!
July 10, 2008 at 1:38 pm
I have tried this but I keep getting syntax errors not sure how to write the query?
July 10, 2008 at 1:50 pm
-- Get Logical file names from backup header
RESTORE FILELISTONLY
FROM DISK = 'your backup file/path here'
-- use logical file info from above in restore statement
RESTORE DATABASE YourDBName
FROM DISK = 'your backup file/path here'
WITH
MOVE 'Logical MDF Name from FILELISTONLY' TO 'Physical location of MDF file',
MOVE 'Logical LDF Name from FILELISTONLY' TO 'Physical location of LDF file',
REPLACE,
STATS
Viewing 7 posts - 1 through 6 (of 6 total)
You must be logged in to reply to this topic. Login to reply