How to shrink db log file

July 18, 2009

(0) Comments

I got this code snippet from my collegue , hope this can be helpful for others too

declare @dbname nvarchar(255)
set @dbname = 'databasename'
backup log @dbname with truncate_only
DBCC SHRINKDATABASE (@dbname, 0)

BALA SINGAM

, ,


1 Star2 Stars3 Stars4 Stars5 Stars (2 votes, average: 3.50 out of 5)
Loading ... Loading ...

No responses to "How to shrink db log file"

No comments yet.

Leave a comment

Name : 
Mail : 
Website : 
Message :