al4629740
asked on
find log file name
I am trying to shrink my log file which is huge in SQL. I am going to use the following to complete the task
Only problem I'm having is , where do I find the logical file name for log file?
USE <db_name>
--find and copy/save the logical name of log file using command below;
--the first column is the logical file name
EXEC sp_helpfile
ALTER DATABASE <db_name>
SET RECOVERY SIMPLE
DBCC SHRINKFILE ( 2 )
ALTER DATABASE <db_name>
MODIFY FILE ( NAME = <logical_file_name_for_log_file>, SIZE = 100MB, FILEGROWTH = 20MB )
Only problem I'm having is , where do I find the logical file name for log file?
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.