cannot restore db from EM to another location

Last Post 16 Jul 2008 02:21 PM by xcao. 2 Replies.
AddThis - Bookmarking and Sharing Button
Author Messages
xcao
New Member
New Member

--
16 Jul 2008 01:29 PM
I tried to restore database from a backup file copied from other server.
I use enterprise manager to restore the database with force overwrite existing.
I want to change the data files to another location, meaning in the backup file it is E:\sql\data, Now I would like to change it to F:\data. so in the option tab, I changed the directory to F:\data, but right after I click to run the restore database, it gives error: file cannot be restored to..., use with move to identify a valid location.

Does this mean I cannot use EM to restore a database to a path different from what is in bak file.

Thanks
xcao
New Member
New Member

--
16 Jul 2008 02:02 PM
I tried to use SQL it gives the same error.
File 'bbadmin_data' cannot be restored to 'F:\bbadmin_data.mdf'. Use WITH MOVE to identify a valid location for the file.

The SQL statement is r

estore database bbadmin
from disk = 'F:\TempBK\bbadmin.bak'
with move 'bbadmin_data' to 'F:\bbadmin_data.mdf',
move 'bbadmin_log' to 'F:\bbadmin_log.ldf'
xcao
New Member
New Member

--
16 Jul 2008 02:21 PM
I figured out, the directory should write something like F:\\ instead of F:\


Acceptable Use Policy
---