Question : SSIS - Execute Process Task (from log text file to SQL server)

I have a package that runs Execute Process Task. In this task, under Process property, the Executable batch file runs Robocopy command to transfer the files and  folders from a source path to a destination path:
robocopy source destination switches

Example:
robocopy "C:\GEDiagnosis" "F:\Label\Test"  /S /E /V /TS /FP /NC /NDL /NJH /NP  /LOG:"F:\Label\Test\log.txt" /R:1 /W:1

This will transfer all the files and folders from C:\GEDiagnosis to F:\Label\Test.
The log.txt file will also be created in the destination file. Sample log.txt is attached here..

I need to transfer the contents of the log text file to SQL Server table. However,
the log file captures the source path information which I need to replace with destination path information.

A line in the log file is:
235    2010/01/01    15:03:23  C:\GEDiagnosis\safety.ppt

But I need it as:
235    2010/01/01    15:03:23   F:\Label\Test\safety.ppt
before I transfer the data into sql server...

Also my log file contains additional information that should not transfer to SQL Server... This is the first line of the log file which shows the path of the log file AS WELL AS all  information  below the "---------------------------" in the file I have attached here as an example...


Attachments:
 
Log text file
 

Answer : SSIS - Execute Process Task (from log text file to SQL server)

I checked it with your file, and any thing is correct,
look at attachement,
I haven't derived column step in my data flow, because i haven't variables values in my package, but you can see result after conditional split, there are 4 rows which have valid values returned


Random Solutions  
 
programming4us programming4us