I currently have a log file that grows very large and I want to write a script to periodicly dump/truncate the files. Form my research it appears to me that the ony way to do this is with a DBCC SHRINKDATABASE command. The problem comes into play that this is a TSQL command I don't know how to execute a TSQL command. I have poked around in Enterprise Manager, but I cant seem to figure it out. Is this the right command to use, and should I even be in Enterprises Manager to use this command?
I'm sorry but I don't know what a DBA is. If its a database administrator then that would be me. How do I dump the database adn DB transaction logs? Sorry if this sounds realy stupid and offends anybody, but I'm new to MS
EXEC sp_addumpdevice 'disk', 'MyNwind_2',
'c:\Program Files\Microsoft SQL Server\MSSQL\BACKUP\MyNwind_2.dat'
--Create the log backup device.
EXEC sp_addumpdevice 'disk', 'MyNwindLog1',
'c:\Program Files\Microsoft SQL Server\MSSQL\BACKUP\MyNwindLog1.dat'
-- Back up the full MyNwind database.
BACKUP DATABASE MyNwind TO MyNwind_2
-- Update activity has occurred since the full database backup.
-- Back up the log of the MyNwind database.
BACKUP LOG MyNwind