Server Fault is a question and answer site for system and network administrators. It's 100% free, no registration required.

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a *.mdf and *.ndf files but *.log is missing. Is it possible to recover the database?

share|improve this question

migrated from Jan 14 '10 at 16:55

This question came from our site for professional and enthusiast programmers.

Try this on ServerFault. – Lance Roberts Jan 14 '10 at 16:37
Why it is programming related as well as this can be done using valid T-SQL. I don't think the server fault folks know that much TSQL. – JonH Jan 14 '10 at 16:39
Are we to guess that you're talking about Microsoft SQL Server? Please be specific. SQL is a language, not a system. – John Gardeniers Jan 14 '10 at 17:49

Look up sp_attach_single_file_db in BOL.

Also you can use:

share|improve this answer

With some third party tools you can. We used Lumigent Log Explorer, which is no longer available. However, if you do a Google (or Bing) search, you will come up with all sorts of alternatives to Log Explorer.

However, your question will get a better answer on

share|improve this answer
I think he will get a better answer on here as it is TSQL related. Serverfault may help if he is looking for a backup but he doesn't have a backup. – JonH Jan 14 '10 at 16:44
@JonH We here on ServerFault know as much or more about administrative T-SQL as the folks at StackOverflow (where many of us also post). – phoebus Jan 14 '10 at 17:24

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.