November 21, 2008 at 10:26 am
Hello All,
I have a ForEachLoop container with a DFT that imports data from multiple files into a single table. I want to have a File System Task with in same ForEachLoop Container to move the files to an archive directory immedietly after each file is imported. Could anyone please let me know any solution or work around to achieve this.
Your help is greatly appreciated.
Thanks,
-Amith Vemuganti
November 21, 2008 at 9:05 pm
Amith,
Within your ForEach loop container, you can map the filename to a variable. After you extract the data from the file (using a DataFlow within that loop), you can then move the file using the Filesystem task. Specify the same variable defined for the filename in the ForEach loop for your source and write the file to your archive folder.
Post back again if you need more help.
hth,
Tim
Tim Mitchell
TimMitchell.net | @tmitch.net | Tyleris.com
ETL Best Practices
November 24, 2008 at 4:13 pm
Thanks for the reply Tim!
I can specify the same variable in File System Task Source. However my destination is dynamic and I want to use a variable. I'm not sure how can I copy multiple files to a dynamic destination.
Please let me know how can I do this.
Thanks,
-Amith Vemuganti
November 25, 2008 at 7:40 am
Amith,
What is the destination component that you use? Certain data flow components support setting their properties thru Expressions. You can check if your destination component property can be set by checking for a property having a name like : [ ]
November 25, 2008 at 7:58 am
Are you using a different destination (e.g., a different folder) for each file? If not, you should be all set. If you want to write each file to a different directory you may need to do some scripting or set up parallel processes.
Tim Mitchell
TimMitchell.net | @tmitch.net | Tyleris.com
ETL Best Practices
Viewing 5 posts - 1 through 4 (of 4 total)
You must be logged in to reply to this topic. Login to reply