469,267 Members | 1,089 Online
Bytes | Developer Community
New Post

Home Posts Topics Members FAQ

Post your question to a community of 469,267 developers. It's quick & easy.

How to restore backupfile from ASP.


i want to restore SQL Server 2000 database backup file
using ASP.I have some code to restore backup file but it
gives an error like "Device is not correct or Device-
offline.see error log files for more details".The relevent
code is:

Set srv=Server.CreateObject("SQLDMO.SQLServer")
srv.Connect "server", "sa", "thanks"
Set rest=Server.CreateObject("SQLDMO.Restore")
rest.Action=0 ' full db restore
rest.Files="D:\Arizona\Arizona_db_200412200200.BAK "
rest.ReplaceDatabase=True 'Force restore over existing
rest.SQLRestore srv

response.write "Done!"

set rest=nothing
set srv=nothing


How can i proceed?please give me the solution.Thanks in
advance.Otherwise could you please tell me,how can i
restore a backup file manually using SQL Server 2000
enterprise adition,Because in my system i don't have
original database,i contain only backup file.Now i want to
retore that file using ASP or manually.


Nov 21 '05 #1
0 850

This discussion thread is closed

Replies have been disabled for this discussion.

Similar topics

4 posts views Thread by Hardy | last post: by
9 posts views Thread by GL | last post: by
11 posts views Thread by Chris | last post: by
5 posts views Thread by gsaray101 | last post: by
5 posts views Thread by damezumari | last post: by
1 post views Thread by CARIGAR | last post: by
reply views Thread by zhoujie | last post: by
reply views Thread by suresh191 | last post: by
By using this site, you agree to our Privacy Policy and Terms of Use.