Discussion Locked

My Data Base Gone. SOS PLease

0 helpful
5 replies
Closed to new repliesThis discussion is closed. It stays readable, but it takes no new replies.

some one has deleted my database in sql server 7.0
now I only have two file ,those are in :
..\sqlserver7\Data\myDB_Data.mdf &
..\sqlserver7\Data\myDB_Log.ldf
Can I gain my database completly again?

5 replies

by m2

try following from Query Analyzer:

sp_attach_db 'myDB', 'c:\MSSQL7\Data\myDB_data.mdf','c:\MSSQL7\Data\myDB_log.ldf'

Good luck to you!

by ron navon

Dear Sir,

Keep the mdf and ldf file in the side, make a data base with the same name, stop the services of SQL change the rename the new mdf and ldf, copy the old mdf and ldf.
restart the server.
I hope that is help you. Ron

This discussion is closed to new replies.