In this post I am posting link, for truncating all log files in Database. link:
http://sharepoint-geek.com/2010/04/07/shrink-all-log-files-within-a-ms-sql-instance/Snapshot of the Script Just incase if removed from above website:
declare @ssql nvarchar(4000)
set @ssql= '
if ''?'' not in (''tempdb'',''master'',''model'',''msdb'') begin
use [?]
declare @tsql nvarchar(4000) set @tsql = ''''
declare @iLogFile int
declare LogFiles cursor for
select fileid ...
Continue reading ...