Home
Mail to developer
FAQ

How to delete the Database Log-file (Transaction Log) of Microsoft SQL Server?

See: http://support.microsoft.com/kb/873235/ru

Also for these purposes you can use the procedure "Detach-Attach", which includes the following steps:

1. Before performing this procedure make sure to do a full back-up copy of the database.

2. Make sure that all users are logged off.

3. Run Enterprise Manager, place the cursor on the database where you want to delete the Log-file.

4. Remember or write down the physical location of the Data- and Log-files of the database. Menu: Properties-Data File/Transaction Log-Location.

5. Do the "detach" of the database. Menu: All Taska-Detach database.

6. In the file manager (Explorer, Far, Total Commander, etc), in the file folder delete Log-file (Transaction Log) of the "detached" database.

7. In the Enterprise Manager, on the Database branch, do "attach" of the previously detached database. Menu: All Tasks-Attach Database, and specify the path to the Data File.

Thus, when you attach a Data-file database, a new (blank) Log-file will be created automatically.

 


<< back
Was this answer helpful for You?
Please tell us how we can make this answer more helpful.

Your comment:


Your e-mail:

Enter the text from the image:         

 
 
© "Double B" JSC, 2023