Results 1 to 2 of 2

Thread: Deleting a Log File

  1. #1
    Jai Guest

    Deleting a Log File

    How can you delete a log file.
    Say I have backed up a transaction log at some drive say G:.
    Now I want to delete this log file and want to define it in a job.
    What is the syntax -
    delete G:Test_log.bak ????
    What is a proper syntax??
    Thanks!

  2. #2
    Jim W Guest

    Deleting a Log File (reply)

    If you want to delete the backup file you made, just delete it using the regular dos delete command or windows explorer. If you don't have file access to the server, you will need to run the dos delete command using xp_cmdshell. ex: xp_cmdshell "del g:Test_log.bak"

    If you want to delete the transaction log file, don't. Truncate the log instead.


    ------------
    Jai at 3/5/01 6:14:29 PM

    How can you delete a log file.
    Say I have backed up a transaction log at some drive say G:.
    Now I want to delete this log file and want to define it in a job.
    What is the syntax -
    delete G:Test_log.bak ????
    What is a proper syntax??
    Thanks!

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •