cancel
Showing results for 
Search instead for 
Did you mean: 

File Adapter (Sender) - Including the source filename into XI-XML

Former Member
0 Kudos

Hello there,

We need to include the name of the source file from the file adapter, into the XML message within XI.

e.g. "interfacefile.dat" -> <filename>interfacefile.dat</filename> in the XML (possibly in the SOAP header?)

We can then use this filename for content based mappings.

Would this be done in the dispatcher?

Does anyone know how to code this in java?

Thanks,

Shawn.

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi Oli,

Thanks for the information. I read the article and I was hoping to use this exit to invoke an xsl to pull in the file name to my xml structure. What file adapter mode did use? How did you pass the fileName object to your xml structure?

Thanks,

Dave

Former Member
0 Kudos

Hello Dave,

I use the mode FILE2XMB. With the dispatcher I create my own XML-Stream, which I write into the TransformResponse paramter of the the function service.

Bye Oli

Former Member
0 Kudos

Oli,

Do you have any code you want to share that shows this?

Thanks,

Dave

Former Member
0 Kudos

Hello together,

in the »SAP Developer Network« I found an article, in which is documented how to write an user-exit in a file-adapter. In this documentation is always explained on which way you've got the filename of the actually parsed file. I have generate an own user-exit and it works fine.

the name of the article is:

How to Write a User-Exit Using the
Dispatcher of the File Adapter

.

Author is Willium Li.

Bye Oli

Former Member
0 Kudos

Hello,

this is also interesting for us. If somebody has a solution for this, let me know this.

Former Member
0 Kudos

Shawn,

Did you find a solution for this? I'm trying to accomplish the same mapping and was hoping you had found a solution. I believe the only way is through the dispatcher but I wanted to know if you used xsl or java and how?

Thanks,

Dave