Skip to Content
author's profile photo Former Member
Former Member

reading file sequentially from FTP using SAP PI file adapter

HI,

I am using SAP PI 7.11 (OS-Windows)

I have a interface where file is being read from a FTP location, using file adapter (sender file communication channel).

The requirement is to read the files from the FTP server one by one (sequentially), maintaining a gap of few minutes between each file access.

I am not allowed to use any OS level script.

Can this requirement be achieved using SAP PI alone.

thanks n regards

Add a comment
10|10000 characters needed characters exceeded

Assigned Tags

Related questions

6 Answers

  • Posted on Oct 27, 2013 at 05:44 AM

    Hi Sudeep,

    You can easily add delay between files by using sleep/choice command in file channel "Run opearting system command after message processing"

    If you have unix system use sleep command

    this will introduce a delay of 60 secs between files

    if you have windows system use choice command:

    choice /c:yn /t:60 /d:y

    Thanks,

    Anand


    Delay.jpg (15.9 kB)
    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 26, 2013 at 03:46 AM

    Hi Sudeep,

    I don't think it is possible to read the files sequentially with a gap of few minuites.

    You may have to pick the files (By Date) and then use BPM for this scenario to induce delay.

    One thread which discusses the same requirement https://scn.sap.com/thread/1472536

    Cheers,

    Ambrish

    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 26, 2013 at 05:57 AM

    Hi Sudeep,

    why don't you try Changing QOS(file channel-> processing tab) to Exactly Once In Order(EOIO) and provide a queue name.

    Thanks

    Hari.


    Add a comment
    10|10000 characters needed characters exceeded

  • Posted on Oct 27, 2013 at 01:45 AM

    Hi Sudeep,

    You can try

    1. Use QOS as EOIO to read files sequentially.

    2. you can provide arbitary name of the queue.

    3. You can use java mapping (in case this is a pass through scenario) to introduce a delay of 1 minute.

    Even you can randomly set this delay interval. If this is not a pass through scenario you can use UDF also to introduce delay in the scenario.This way you can ensure that there is a few minute delay between processing of files. Please check this thread http://scn.sap.com/thread/3433549 and my response to it. This logic is to be transformed into java mapping.

    Regards

    Anupam

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Oct 28, 2013 at 05:23 AM

    Hi Sudeep

    Use EOIO in sender adaptere and then go for BPM. In NWBPM the delay can be put easily. Check the

    blog below

    http://scn.sap.com/community/bpm/blog/2013/09/27/sequential-split-of-messages-and-looping-in-nwbpm-process-using-indexing-of-record

    Add a comment
    10|10000 characters needed characters exceeded

  • author's profile photo Former Member
    Former Member
    Posted on Nov 09, 2013 at 09:45 AM

    HI All,

    Thanks for all responses. Finally i have decided to use a script at OS level to move files from one folder to another introducing a delay, as i think its easy to implement without disturbing the existing interface design.

    But now struggling with another hurdle. In the OS level (Windows 2008) i have scheduled the script to move files every 1 min. But the client requirement is to have lesser duration. And in Windows 2008, there is no option to schedule a job with interval of less than 1 min. Trying to see if that can be done somehow.

    Add a comment
    10|10000 characters needed characters exceeded

    • Former Member

      Hi Sudeep,

      Follow up question if possible, you said "And in Windows 2008, there is no option to schedule a job with interval of less than 1 min". Did you find a solution to overcome this?

      Thanks,

      Jake.

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.