Monday, August 2, 2010

Syntax of Shrinking SQL Server database mdf and log file

The below code snippet will help you to shrink the database. Run the code snippet through your SQL Server query analyser.
















backup log with truncate_only
use
dbcc SHRINKFILE (,2)
dbcc ShrinkDatabase (, 2)

No comments:

Post a Comment