Monday, March 26, 2012

Problem with attaching database

I try to attach a db by running the following command:

EXEC sp_attach_single_file_db @.dbname = 'test',

@.physname = 'C:\Documents and Settings\renee.wilson\My Documents\PD DD 2.nvp'

But I get the following error message:

File activation failure. The physical file name "C:\Documents and Settings\renee.wilson\My Documents\PD DD 2_log.LDF" may be incorrect.

The log cannot be rebuilt because the database was not cleanly shut down.

It looks like that the db was not detached from the server properly. I know that .LDF file does not exist, therefore, I was hoping by running the sp_attach_single_file_db, a new .LDF file can be created.

Any body has any idea on how to fix the problem? Thanks in advance.

Hi,

one last chance left, here are some instructions for the crashd database:

http://groups.google.de/group/microsoft.public.sqlserver.server/browse_frm/thread/f584b644548cd68f

HTH, Jens Suessmeyer.

http://www.sqlserver2005.de

|||

Thanks, Jens.

But, I tried both suggestions in

http://groups.google.de/group/microsoft.public.sqlserver.server/browse_frm/thread/f584b644548cd68f

without much luck.

I am having the following problems:

1. DBCC rebuilt_log does not exist in SQL Server 2005 Express which I am using.

2. When the database is in emergency mode, which I can see via the tool(Microsoft SQL Server Management Studio Express) I am using, I can not view any of its object, for example, I click on Tables(try to see the tables), I get error msg: Could not continue scan with NOLOCK due to data movement, (Microsoft SQL Server, Error:601). For the same reason, I can not generate scripts as suggested.

Any further suggestion? Thanks in advance.

No comments:

Post a Comment