cancel
Showing results for 
Search instead for 
Did you mean: 

PDF via file to file

Former Member
0 Kudos

Hi experts,

I have now searched quite long in this forum to find some help for my problem but so far I did not succeed.

My scenario is simple: one file sender to pick up a pdf file and on the other hand a file receiver to write this pdf document to another directory.

Regarding this blog [/people/william.li/blog/2006/09/08/how-to-send-any-data-even-binary-through-xi-without-using-the-integration-repository|/people/william.li/blog/2006/09/08/how-to-send-any-data-even-binary-through-xi-without-using-the-integration-repository] this seems to work without IR and much efford. I have created the scenario as described and the pdf file is getting picked up and posted forward to my target directory. However, when I open the pdf document there are only cryptical signs. My guess is that I need to configure my file receiver to handle pdf documents but this is not described in the blog. I hope I can use payload swap beans for pdf but I am totally lost with this issue as I have never worked with them. I already tried this blog [/people/michal.krawczyk2/blog/2005/12/18/xi-sender-mail-adapter--payloadswapbean--step-by-step|/people/michal.krawczyk2/blog/2005/12/18/xi-sender-mail-adapter--payloadswapbean--step-by-step] but it seems it does not help to replace xml by pdf. Can anyone give me a short guide how to use the payload swap with pdf? That would be great.

Regards.

Oliver.

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

You definitely need no payload swap or whatever bean for this scenario. I have done the same (PDF 2 PDF via file), and it works without problem. The type must be binary, as explained by others. Just route if through PI, as described in that blog.

Are you sure that the incoming file is still correct ? How does this file come to PI ? Can it be that someone forgot to set binary in an FTP transfer which sends the file to PI ?

How different are the source and target filesregarding file size ?

CSY

Former Member
0 Kudos

It's alright. It's working fine. It worked fine all the time but I always tried to open the pdf document via WinSCP which uses a text editor for this document type. After downloading the file it is shown correctly.

Thanks for the hint with the file size. That's what brought me to the solution.

Best regards.

Oliver.

Answers (3)

Answers (3)

Former Member
0 Kudos

Oliver ,

If you are picking the file and posting it in binary mode there should not be any issue .

I don't think you need to use "payload swap beans " concept as the mapping program will also be dummy thus the communication channels will work purely as FTP commands for picking and posting the file .

Regards ,

Former Member
0 Kudos

Well, I have both channels already in binary mode. It's already set by default. That means, if you mean the transfer mode.

Best regards.

Oliver.

P.S.: The advanced source file selection did not work either. I have exactly the same output.

Edited by: Oliver Vöpel on Mar 2, 2010 3:17 PM

Former Member
0 Kudos

HI,

You should have binary for the "FileType" parameter in processing tab for both the channels.

pls do post if the problem is not resolved.

Best Regards,

Lakshmi

Former Member
0 Kudos

Sorry, but file type is binary in both channels, as well. Also set by default.

Best regards.

Oliver.

Former Member
0 Kudos

Did you check few parameters in advanced tab in both the channels

Use Adaper-specific message attributes.

FileName

FileType

Former Member
0 Kudos

Yes, I tried this as well. Same result. Maybe it's because we have PI 7.1 and not 7.0?

Best regards.

Oliver.

Former Member
0 Kudos

Hi Oliver,

In the sender communication channel (In the source tab) Check the Additional file(s) check box and give the File name with source directory/path (in the File List) then it takes the files and send it to the target folder without any modifications.

Regards

Ramesh

former_member187339
Active Contributor
0 Kudos

Hi Oliver,

Try reading and writing the PDF in a binary form (Use binary mode in the communication channel)

Regards

Suraj