Skip to Content
0

Dynamic configaration

May 30, 2017 at 02:41 AM

134

avatar image

I want create dynamic file name in the target system based target payload.

I think we need to create UDF for this.

My question is where we need map this UDF in mapping level

Regards,

Chandu

10 |10000 characters needed characters left characters exceeded
* Please Login or Register to Answer, Follow or Comment.

4 Answers

Harish Mistri May 30, 2017 at 03:40 AM
0

Hi Chandra,

There are three option to create the dynamic file name. Dynamic configuration, Variable substitution, and operating system command.

For your scenario, the variable substitution will work as you have derived the name from output field value. Please refer the below wiki for more details

https://wiki.scn.sap.com/wiki/display/XI/Dynamic+file+name+and+directory+in+Receiver+File+Adapter+-+summary+of+possibilities

regards,

Harish

Share
10 |10000 characters needed characters left characters exceeded
chandrasekhar reddy May 30, 2017 at 05:10 AM
0

whenever using dynamic configuration we need to create UDF right. that time where we need to map the UDF in mapping.

Show 1 Share
10 |10000 characters needed characters left characters exceeded

UDF is for dynamic configuration varibale. Please check the wiki, the UDF sample code is given in that

String filename = new String("");
DynamicConfiguration conf1 = (DynamicConfiguration) container.getTransformationParameters().get(StreamTransformationConstants.DYNAMIC_CONFIGURATION);
DynamicConfigurationKey key1 = DynamicConfigurationKey.create("http:/"+"/sap.com/xi/XI/System/File","FileName");
filename = "xi_output_" + variablePart + ".xml";
conf1.put(key1,filename);
return variablePart;

0
Evgeniy Kolmakov May 30, 2017 at 06:20 AM
0

Hi Chandu!

As Harish has already explained you create UDF to put element value to DC and in your message mapping you can map its result to target message's root node, for example, or to variable that you create for target structure.

Regards, Evgeniy.

Show 1 Share
10 |10000 characters needed characters left characters exceeded

thanks for the giving answer

0
chandrasekhar reddy May 30, 2017 at 06:14 AM
0

we need write Java coding ok but where we need to use in this UDF in mapping level.

Show 2 Share
10 |10000 characters needed characters left characters exceeded

You can use this UDF anywhere of the mapping. Like below -

Thanks,

Apu

p6ygk.png (70.5 kB)
0

thanks you so much

0