cancel
Showing results for 
Search instead for 
Did you mean: 

Multiple archive directories in File sender channel using one Interface

former_member601407
Participant
0 Kudos

Hi,

Scenario:

File to File scenario (no mapping involved). We have multiple files in multiple folders which has to be archived to the respective archive folders. I was able to pick files from different directories using "Advanced Selection for source file", but not able to archive it in respective folders. For Eg:

Source Directories:

Interface/abc/

Interface/bcd/

Interface/cde/

Corresponding Archive directories:

Interface/abc/archive

Interface/bcd/archive

Interface/cde/archive

I referred the below thread where they are recommending to go for running OS script after placing files in one single archive directory.

https://answers.sap.com/questions/8089561/multiple-archive-directories-in-sender-file-channe.html

Please recommend if there any other solution. I don't want to use multiple interfaces, because i have eight different folders.

Any help would be appreciated.

ryan.crosby

Accepted Solutions (0)

Answers (2)

Answers (2)

Ryan-Crosby
Active Contributor

Hi Subin,

I don't know if the dynamic configuration is honored in the archive directory settings (have never had reason to try it). If it were to work you would still need to generate the dynamic reference with the addition of the /archive value in some manner. Aside from the options mentioned in the attached post you could create a secondary receiver in a single flow where you would generate the value for the dynamic configuration key.

Regards,Ryan Crosby
JaySchwendemann
Active Contributor

If you would be ok with the files being physically all in one archive directory and if the then archived files would be identifiable by means of file attributes (name, file type, size, ...) for an os to filter them you could try some kind of directory filtering like mentioned here: https://unix.stackexchange.com/questions/389994/how-to-create-a-filtered-view-of-a-directory

The idea then would be:

  • Configure PI to archive files from all input directories to a single archive directory
  • Configure your OS such way that you end up with filtered "directory views" that only show a subset of your files.
  • Maybe this can be combined with the already mentioned solutions to get the desired behavior or at least get close to it

Cheers

Jens