cancel
Showing results for 
Search instead for 
Did you mean: 

Handling Files as attachment (Scenario File --> PI --> SOAP) SAP PI 7.31

Former Member
0 Kudos

Hi experts,

i need help regarding upload file from FTP directory. The structure of that file (file suffix *.msg) is unknown.The File have to be forward as attachment encrypted with base64 to SOAP.

I found following article in the scn which could fit to our scenario:

http://scn.sap.com/people/community.user/blog/2005/07/15/copy-a-file-with-same-filename-using-xi

Can anybody send me an example code of implementing an adapter module for encrypting a file to base64 like the ReadFileBean in the above article.

Or is there in SAP PI 7.31 an easier way to implement this?

Thank you.

Regards

Mario

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member181985
Active Contributor
0 Kudos

Hi Mario,

You can achieve this in PI7.31 using a java mapping. Read the incoming payload as bytes and then convert it into a base64 data and then create an attachment. You can also formulate required SOAP payload (may be some dummy data or with required data) via java mapping.

Best Regards,

Praveen Gujjeti

subhro_de
Active Participant
0 Kudos

Hi Mario,

Is using java mapping to put the payload in base64 in mapping and then using PayloadSwapBean to swap the payload as attachment. In case of writing the payload as attachment in java mapping as well in PI 7.31 ICO please refer to the link below :

http://scn.sap.com/community/pi-and-soa-middleware/blog/2013/09/16/risks-in-migrating-to-ico-there-a...

Regards

Subhro