You Tube

Saturday 6 April 2024

How to Shrink Database Log File

 1st find out the logical name of the Database. using this
SELECT name FROM sys.master_files WHERE database_id = DB_ID('DataBaseName')


Now Execute this query with logical name of the Database.
DBCC SHRINKFILE('LogFile Name', 50);

now log file is 51MB or somthing

No comments:

Post a Comment