cancel
Showing results for 
Search instead for 
Did you mean: 

SAP CPI to pick the files from SFTP location in particular sequence

R_Swetha1
Explorer
0 Kudos
561

Hi Experts,

In SAP CPI we have a requirement to pick the files from SFTP location in particular sequence.

For example, source systems places three files daily in SFTP location

Newfile_050824.csv
Testfile_050824.csv
Changefile_050824.csv

CPI has to pick the files in below sequence 

first file :Testfile_050824.csv
second file :Changefile_050824.csv
third file  Newfile_050824.csv

 and route the files to a process call where it has steps to change the structure.

Please let me know how to pick the files in the above order from cpi. Thanks in advance.

View Entire Topic
Ryan-Crosby
Active Contributor
0 Kudos

Choose more appropriate names and then use the "Filename" sorting strategy on the SFTP polling setup.

 

Regards,

Ryan Crosby

R_Swetha1
Explorer
0 Kudos
Filename sorting strategy picks files in alphabetical order.But as per the requirement I have to pick the files in the given order.How this can be done ?
Ryan-Crosby
Active Contributor
0 Kudos
@R_Swetha1 you can't with a single poll because those are not in alphabetical order, which would only leave the option of multiple polls in a sequence.
Swetha_3
Discoverer
0 Kudos
How to handle with multiple polls in sequence
Ryan-Crosby
Active Contributor
0 Kudos
@Swetha_3 you would need to use poll enrich which would result in all payloads existing in a single message.