-
database backup and recover
Hi all:
In order to test database restore, I create a backup driver and puporse delete one table, then I try to restore my databse use backup, but the delete table donot show up.
Thank you
________
R51
Last edited by sql; 03-06-2011 at 01:21 AM.
-
I believe you are using sql server.
Did you do the following?
use master
go
backup database yourdatabase to disk = 'd:\yourdatabase.bak' with init
go
use yourdatabase
go
drop table yourtable1
go
delete yourtable2
go
use master
go
restore database from disk = 'd:\youdatabase.bak' with replace
go
use yourdatabase
go
select * from yourtable1
go
select * from yourtable2
-
database back and recover
Hi:
Thank you for the reply, I try by code and wizards, it did work, but after RESTORE DATABASE successfully, I can't saw the table that I delet in tables list when I went to my database and click the tables. may I know why??
I figure up this by use the select suggest from your advice.
by the way
I use the code like
backup database pubs
to disk ='c:\pubsdump.dat'
with description='Pubs test backup' ,
init,
stats=9
it can create a backup driver.
why you suggest master in here?
________
Daihatsu Materia History
Last edited by sql; 03-06-2011 at 01:21 AM.
-
you cannot restore a database when you are in that database. it is like cutting a branch (in a tree) by standing on that branch (at the far end).
-
May be it is not refreshed.
Right click on the database and select Refresh.
-
Hi all:
thank you
________
BUBBLER PIPE
Last edited by sql; 03-06-2011 at 01:21 AM.
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
|