Sunday, March 25, 2012

attach data file

I have MS SQL server database with two files
1- x_data.mdf, 2- x_log.ldf
The database become suspect and i have no space problem.
now the problem is that the log file become corrupted because when i stop the database service I tray to copy the log file into another place but I can't
Now the result is that I have one data file x_data.mdf and how can I solve the problem
and the question is how can I back the data again when I have a data file without a log file
Thankstry attaching the database file.
right click server --> attach database.
while attaching it recreates the log file.

No comments:

Post a Comment