프로그래밍/DB
MSSQL 트랜잭션 로그 축소
Super User
2012. 11. 2. 10:42
USE SMT;
GO
-- Truncate the log by changing the database recovery model to SIMPLE.
ALTER DATABASE SMT
SET RECOVERY SIMPLE;
GO
-- Shrink the truncated log file to 1 MB.
DBCC SHRINKFILE (SMT_Log, 1);
GO
-- Reset the database recovery model.
ALTER DATABASE SMT
SET RECOVERY FULL;
GO