Weird issue with SSIS logging.

  • Hello, Today I really faced a weird error with SSIS logging. What my package (ScriptTask) is trying to do is delete folders at specific path.

    Also I enabled logging from my Script Task to log the total number of folder deleted from the script task. I am writing logs to text file appended by timestamp(Format: LogPath\PackageName~YYYY.MM.DD~HH.MM.SS). Problem is my package is creating 2 logs instead of 1.

    Second issue that I am facing is in writing time in in file as HH.MM.SS format as @[System::StartTime] output time as 1:25.9 (I need 01.25.09)

    I am attaching my package and log output.

    I guess it is something silly mistake that I have done but not able to find out.

    __________________________________________
    ---------------------------------------------------
    Save our mother Earth. Go Green !!!

  • It looks to me like this is a byproduct of running it in BIDS. When you open the package in BIDS it creates the first log file and then when you run it it creates the second log file which is the one that is written to. If you run the package using the package Execute Utility you only get one log file for the execution.

  • I tried running it with DTEXEC utility. Still the same output.

    __________________________________________
    ---------------------------------------------------
    Save our mother Earth. Go Green !!!

  • Regarding the time format: you'll have to add the zero's yourself in the expression. You can do this by converting the number to string and use the following formula:

    RIGHT('00' + myColumn,2)

    I took a look at your package, but at first sight the configuration of the logging seems OK.

    Need an answer? No, you need a question
    My blog at https://sqlkover.com.
    MCSE Business Intelligence - Microsoft Data Platform MVP

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply