FOR EACH loop Container

  • Hi all,

    I am new to FOR EACH loop container and need some information on how to handle error in looping through FILES,

    In case if one file has an error, how to make sure it works still smoothley...

    Thanks

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • There is a max errors property, set it to zero. You might have to set it for a couple different components within the FOR EACH but it will ignore the errors, HOWEVER, YOU should handle them in some way.

    CEWII

  • We cannot properly answer your question without knowing what you want to happen when there's an error with a file.



    Alvin Ramard
    Memphis PASS Chapter[/url]

    All my SSC forum answers come with a money back guarantee. If you didn't like the answer then I'll gladly refund what you paid for it.

    For best practices on asking questions, please read the following article: Forum Etiquette: How to post data/code on a forum to get the best help[/url]

  • Hi,

    thanks for your reply

    -I got a way to do what I was trying to in this useful link

    but now I was using a File System task (instead of SCRIPT task shown)to MOVE that file from that location to another location -ERROR FILES folder

    but I am not able to move it (error file), instead I tried to COPY it and it copied properly...any help on how to move this file now to a different location..

    Thanks

    [font="Comic Sans MS"]
    ---------------------------------------------------

    Thanks [/font]

  • ssis learner__ (9/2/2010)


    Hi,

    thanks for your reply

    -I got a way to do what I was trying to in this useful link

    but now I was using a File System task (instead of SCRIPT task shown)to MOVE that file from that location to another location -ERROR FILES folder

    but I am not able to move it (error file), instead I tried to COPY it and it copied properly...any help on how to move this file now to a different location..

    Thanks

    OnError in Foreach Loop direct your task to FST(File System Task) and do the needful...you will be having the variable with file name so in your FST your scource will vary but your destination will remain same.

    :cool::cool:

    Raunak J

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

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