How to recover database from MDF in SQL Server 2005?

后端 未结 9 445
野性不改
野性不改 2021-01-31 11:20

I have an MDF file and no LDF files for a database created in MS SQL Server 2005. When I try to attach the MDF file to a different SQL Server, I get the following error messa

9条回答
  •  滥情空心
    2021-01-31 12:21

    have you tried to ignore the ldf and just attach the mdf:

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

    i don't know exactly what will happen to your open transactions (probably just lost), but it might get your data back online.

    -don

提交回复
热议问题