USE YourDatabaseName
GO
--Run this script to get your TransactionLogName
SELECT * FROM sys.sysfiles
GO
DBCC SHRINKFILE(TransactionLogName, 1)
BACKUP LOG YourDatabaseName WITH TRUNCATE_ONLY
DBCC SHRINKFILE(TransactionLogName, 1)
GO
Friday, December 3, 2010
Shrinking Truncate Log File
at 1:13 AM
Labels: DBA Tasks, SQL Server, SQL Server Tip
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment