Skip to Content
0

How do I send a CSV file from one SFTP to another SFTP with non-English characters?

Oct 11, 2017 at 06:49 PM

80

avatar image

The Scenario

A vendor is uploading a CSV file on their SFTP site. I have configured PI to pull that file, decrypt the file using our PGP private key (since the CSV file placed on the vendor's SFTP site has been encrypted with our PGP public key), and then send the file to another SFTP site from which another team is pulling the file for Qlikview consumption.

The Issue

I am able to successfully decrypt the CSV file and send it to the other SFTP. However, within this CSV file there are some non-English characters, such as ü and ä, which do not show up correctly once the file reaches the second SFTP site. This is not an issue with the encryption/decryption of the file because as of now I have asked the vendor to not encrypt the test file (and thus PI is currently not decrypting anything, just pulling the file and sending it to the second SFTP site). Even with the file not having PGP Encryption/Decryption applied to it, these non-English characters are still not showing up correctly on the second SFTP site. These non-English characters show up just fine on the original SFTP site, though. Please note that as of now the vendor is only able to generate the file in CSV format. Any customization to the report would require additional funds and would perhaps make it more difficult to add other fields later on. So, the file must stay in CSV format.

*Adapter type is SFTP for both channels in this configuration.

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

2 Answers

avatar image
Former Member Oct 12, 2017 at 07:03 AM
2

Hi,

you can use MessageTransfromBean to change the encoding to UTF-8

Modul:

localejbs/AF_Modules/MessageTransformBean as conversion

Paramter:

conversion Transform.ContentType text/plain;charset=UTF-8

Regards,

Alex

Share
10 |10000 characters needed characters left characters exceeded
Mark Dihiansan Oct 12, 2017 at 07:05 AM
1

Hi Elna,

I guess your SFTP adapter does not have the option to set the encoding right?

This blog will be a good read https://blogs.sap.com/2015/02/22/handling-code-page-character-encoding-in-sap-pi-po/

Regards,

Mark

Share
10 |10000 characters needed characters left characters exceeded