Click here to Skip to main content
Licence 
First Posted 24 Apr 2002
Views 84,492
Bookmarked 14 times

Clear the transaction log

By | 25 Apr 2002 | Article
dump the transaction log
 
Part of The SQL Zone sponsored by
See Also

Introduction

How To Clear A SQL Server Transaction Log

[Transaction Log full error]
DUMP TRANSACTION [database_name] WITH NO_LOG

- From the desktop of the machine having the problem, go to Start -> Program Files -> Microsoft SQL Server 6.5


- Launch ISQL_W

- A screen asking you to connect will appear. Fill in the name of the machine you are working on (for example, GEOCSCOLGRA and click Connect. If you have successfully connected a query window will appear.

- Open the drop down menu at the top of the query window. Highlight the name of the database that is having the problem (for example, csco_sideA)

- Type in the following statements. Put each statement on a separate line. Modify the text in bold (for example, change to csco_sideA):
dbcc checktable (syslogs)
dump tran with no_log
dbcc checktable (syslogs)
dbcc perflog


License

This article has no explicit license attached to it but may contain usage terms in the article text or the download files themselves. If in doubt please contact the author via the discussion board below.

A list of licenses authors might use can be found here

About the Author

Fernando Finelli

Web Developer

Argentina Argentina

Member

Lic. Fernando Finelli

Sign Up to vote   Poor Excellent
Add a reason or comment to your vote: x
Votes of 3 or less require a comment

Comments and Discussions

 
You must Sign In to use this message board. (secure sign-in)
 
Search this forum  
 FAQ
    Noise  Layout  Per page   
  Refresh
GeneralFor those of you with SQL Server 2000 PinmemberRichard Bywater22:17 14 May '02  
Microsoft recommends that you use BACKUP instead of DUMP as DUMP is only included for backward compatibility and will not be exist in a future version (although they don't say what version Smile | :) )
 
BACKUP works the same way really:
BACKUP LOG databasename WITH TRUNCATE_ONLY or
BACKUP LOG databasename WITH NO_LOG
 
NO_LOG & TRUNCATE_ONLY are synonyms. Personally I prefer TRUNCATE_ONLY 'cos it truncates the log file but its always up to personally preferences I guess Smile | :)
 
Richard.
(If my advice breaks something OMG | :OMG: , don't blame me Smile | :) )

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.

Permalink | Advertise | Privacy | Mobile
Web01 | 2.5.120529.1 | Last Updated 26 Apr 2002
Article Copyright 2002 by Fernando Finelli
Everything else Copyright © CodeProject, 1999-2012
Terms of Use
Layout: fixed | fluid