cancel
Showing results for 
Search instead for 
Did you mean: 

How to read .tar file?

umesh_badveli
Participant
0 Kudos

Hi All,

I have a scenario .tar file to SAP .

Kindly advise me how to read .tar using PI

Regards

Umesh

Accepted Solutions (0)

Answers (2)

Answers (2)

former_member190293
Active Contributor
0 Kudos

Hi Umesh!

I've never implemented scenarios in which .tar files were used, but I guess, that processing such files shouldn't be a kind of problem. You could try to use Apache Common Compress library to fulfill your requirement:

https://stackoverflow.com/questions/315618/how-do-i-extract-a-tar-file-in-java/7556307#7556307

At first sight, it's similar to .zip files processing in Java.

Regards, Evgeniy.

iaki_vila
Active Contributor
0 Kudos

Hi Umesh,

Are you sure that you have to unzip the .tar file?, i mean, you can have a File to File scenario, and to deposit the file in filesystem accesible by SAP ERP ant this SAP ERP would be the responsible for unzip. If you have to unzip, you will need to do:

Option 1 Java code like here https://blogs.sap.com/2013/04/29/module-payloadgzipbean-zip-and-unzip-payloads-using-gzip-2/ , also you can do an UDF.

Option 2. Install in the OS system a program to zip/unzip these kind of file and to call this OS command from file adapter.

Regards.