cancel
Showing results for 
Search instead for 
Did you mean: 

Use xml field in file name scheme

Former Member
0 Kudos

Hello,

I have the following xml structure, and in the name tag I have the file name that i want to use in the file receiver adapter:

<NAME>FN_OUT.txt</NAME>

...

How can i reference that tag of my xml in the File name scheme of the file receiver adapter, i think is something like this: %name but im not sure..

Can anybody help me please?

Thanks in advance,

Luis

Accepted Solutions (1)

Accepted Solutions (1)

Former Member
0 Kudos

Thanks a lot for your help,

Do you know if there is any weblog that shows such functionality??

Regards,

Luis

Shabarish_Nair
Active Contributor
0 Kudos

see to the last half of this weblog on how the author has used the functionality - /people/jayakrishnan.nair/blog/2005/06/20/dynamic-file-name-using-xi-30-sp12-part--i

Do post in case you still need clarifications !!!

bhavesh_kantilal
Active Contributor
0 Kudos

Hi,

Take a look at this blog,

/people/sameer.shadab/blog/2005/09/23/an-interesting-usage-of-variable-substitution-in-xi

It show the receiver service. For the payload, just follow the help link similarly.

Regards,

Bhavesh

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi,

I think that with this info is enough for solving my problem, thanks a lot for your help!

regards,

Luis

Shabarish_Nair
Active Contributor
0 Kudos

I guess you need info on how to use variable substitution in your adapter.

Ref the Variable Substitution (Target Directory/File Name Scheme) section of the help link http://help.sap.com/saphelp_nw04/helpdata/en/bc/bb79d6061007419a081e58cbeaaf28/content.htm.

Also ref this blog on how to remove the extra tag in case you need to as it is in most situations - /people/sravya.talanki2/blog/2005/08/11/solution-to-the-problem-encountered-using-variable-substitution-with-xi-sp12

bhavesh_kantilal
Active Contributor
0 Kudos

Hi,

The dynamic filename generation concept is as follows.

In your filename field. just give a variable with % symbols. (eg: %file% ).

Now, under the option Variable Name Substitution, you can give how the value has to be created.

It can be your interface name, sender service name, etc or it can be some value dynamically from your payload.

For the former, your give

message:interface_name ,etc

and for the payload part you give,

Payload: "your element root which u wanna acecss"

Just check this link out,

http://help.sap.com/saphelp_nw04/helpdata/en/bc/bb79d6061007419a081e58cbeaaf28/content.htm

And read the contents under variable substitution and it will help you understand the concepts better.

Regards,

Bhavesh