cancel
Showing results for 
Search instead for 
Did you mean: 

Dynamic file name in Receiver File Adapter

Former Member
0 Kudos

Hi,

Can any one tell how to set the file name in the destination directory in the receiver file adapter dynamically.

Accepted Solutions (1)

Accepted Solutions (1)

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.

If you have any clarifications, do get back,

Regards,

Bhavesh

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

You could set filenames dynamically in the following ways:

1. Using variable substitution:

This can be used if name of the file is to be taken from the payload or from xml attributes.

2. Using counters:

There is an option of adding a counter value as part of the filename available in the receiver file adapter.

Regards,

Smitha.

Former Member
0 Kudos

hi smitha.

u r anser is understandable to me.

but where i can find variable substitution and counter .

could u explain it clearly.

waiting for u r turn.

ye.

regards.

seeta ram.

Former Member
0 Kudos

Hi,

You could find this in the receiver file adapter.

Click on the Variable substitution 'Enable' checkbox. In the text space that appears, type in the value of the variable.

The link provided by Bhavesh in the above post would help you better.

Regards,

Smitha.

santhosh_kumarv
Active Contributor
0 Kudos

Hi

U can use the variable substitution to determine the file name/ directory the output file to be placed dynamically.

So u configure the receiver adapter with the variable substution parameters.

For more Info go thru this Blog's

<a href="/people/jayakrishnan.nair/blog/2005/06/20/dynamic-file-name-using-xi-30-sp12-part--i File Name using XI 3.0 SP12 Part - I</a>

<a href="/people/jayakrishnan.nair/blog/2005/06/28/dynamic-file-namexslt-mapping-with-java-enhancement-using-xi-30-sp12-part-ii File Name using XI 3.0 SP12 Part - II</a>

Regards

Santhosh

[url=; Use a Good Subject Line, One Question Per Posting - Award Points[/url]

bhavesh_kantilal
Active Contributor
0 Kudos

Pravesh,

Apart from my previous post, you can also use Adapter Specific Identifiers in your Sender and Receiver File Adapters to copy the same file name from the source to the target.

take a look at this blog for the same,

/people/michal.krawczyk2/blog/2005/11/10/xi-the-same-filename-from-a-sender-to-a-receiver-file-adapter--sp14

Regards,

Bhavesh