RE: Recreate deleted .ldf file?

RE: Recreate deleted .ldf file?

 

  

You can attach just the mdf like so.
If it is "suspect, you probably need to "sp_detach" it first.
Physical_name is the path and file name of the mdf.


sp_attach_single_file_db [ @dbname = ] 'dbname'
, [ @physname = ] 'physical_name'


Dano Smith



-----Original Message-----
From: Maceyunas Joe
[mailto:mssqldba-ezmlmshield-x69399680.[Email address protected]
Sent: Monday, April 30, 2007 10:58 AM
To: LazyDBA Discussion
Subject: Recreate deleted .ldf file?
Importance: Low

Hello,
A developer deleted an .ldf file to a test database. As it turns out the
database wasn't so test after all.
The guy didn't backup his DB and there are no current copies of the
.ldf. I can see the MDF in windows
Explorer and its current file size is around 1.5gb. Enterprise manager
shows the DB as suspect and I can't do
any sort of properties display on it. I cant detach nor back up the DB,
Is there any way of creating a new ldf file?

Thanks.


DISCLAIMER:
The information contained in this transmission may contain privileged
and confidential information. It is intended only for the use of the
person(s) named above. If you are Not the intended recipient, you are
hereby notified that any review, dissemination, distribution or
duplication of this communication is strictly prohibited. If you are not
the intended recipient, please contact the sender by reply email and
destroy all copies of the original message.



---------------------------------------------------------------------
TO REPLY TO EVERYBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY
To post a dba job: http://jobs.lazydba.com
To subscribe : http://www.LazyDBA.com
To unsubscribe: http://www.lazydba.com/unsubscribe.html



MS Sql Server LazyDBA home page