Shrink a 2005 SQL Log File
October 21st, 2009 adminIf you have a 2005 SQL log file which is growing out of control – here are the steps needed to truncate it:
In SQL Server Management Studio – start a new query:
USE <DB Name>
Go
select * from sys.database_files
This will give a list of all database files – you’re looking in the “name” column for the name of the log file you want to shrink.
In a new query:
USE <DB Name>
Go
DBCC SHRINKFILE (‘<name from previous query>’, 1)


