on 12-02-2011 6:10 PM
Hi All,
I have done the mapping to create multiple output messages . I would like each of the messages to be stored as a separate file in the target .
Below is the output message with 2 separate MT_CANCELOUT messages . However, both end up in one single xml file .
How do I configure the receiver file adapter to ouput 2 separate xml files ?
<ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
<ns0:Message1>
<ns1:MT_CANCELOUT xmlns:ns1="urn://gm.com:VBVTEST">
<LineItem>
<id>456</id>
<name>HEY</name>
</LineItem>
</ns1:MT_CANCELOUT>
<ns1:MT_CANCELOUT xmlns:ns1="urn://gm.com:VBVTEST">
<LineItem>
<id>567</id>
<name>RAT</name>
</LineItem>
</ns1:MT_CANCELOUT>
</ns0:Message1>
</ns0:Messages>
Hi Michel,
I am also having the same requirement. In my scenario, i have to deliver a multiple file based on the input database values and i have to update the SAP system with the message. So i have used multimapping. One message is to create a file and other message is to create a input for SAP system.
Now my problem is i dont know how many files i need to generate in the output. If i get the 5 input values then i have to generate 5 output messages. then FILE adapter easily generate file for each input. How to do in message mapping. please give some guidness to do this.
Regards,
Ramalakshmi.G
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
There are many ways to create multiple target files. Are you using BPM? or without BPm?
Example: Refer this link
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thanks for the responses.
Raj, I tried changing the file construction mode to "Create", "AddTimestamp" and "Addcounter" , but it still outputs only one file .
I have done it without BPM , using multimapping . So there is no problem with the mapping. I am getting 2 separate messages (as shown in my previous post) .
Problem is how to configure Receiver File Adapter to output separate files , one for each message.
Hi,
Sorry to say you that but your post show the opposite, it shows you have only one target message !
<ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
<ns0:Message1>______<<<<<<<
<ns1:MT_CANCELOUT xmlns:ns1="urn://gm.com:VBVTEST">
<LineItem>
<id>456</id>
<name>HEY</name>
</LineItem>
</ns1:MT_CANCELOUT>
<ns1:MT_CANCELOUT xmlns:ns1="urn://gm.com:VBVTEST">
<LineItem>
<id>567</id>
<name>RAT</name>
</LineItem>
</ns1:MT_CANCELOUT>
</ns0:Message1>______<<<<<<<
</ns0:Messages>
If you want two files, you should generate two Messages, and so to do that:
In MM, in your target (tab before "function"), you should have 1 source MT and in target MT, you should have two lines (even if you use the same target MT), after having changed the ouccurence 1->N.
do the same in your operation mapping: 1->N with two receiver service interface (even if it's the same)
because you should have something like:
<ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
<ns0:Message1>
<ns1:MT_CANCELOUT xmlns:ns1="urn://gm.com:VBVTEST">
<LineItem>
<id>456</id>
<name>HEY</name>
</LineItem>
</ns1:MT_CANCELOUT>
</ns0:Message1> _____<<<<<<<
<ns0:Message2> _____<<<<<<<
<ns1:MT_CANCELOUT xmlns:ns1="urn://gm.com:VBVTEST">
<LineItem>
<id>567</id>
<name>RAT</name>
</LineItem>
</ns1:MT_CANCELOUT>
</ns0:Message2>
</ns0:Messages>
regards
mickael
Edited by: Mickael Huchet on Dec 2, 2011 8:58 PM
execute your scenario end to end then check in moni inbound payload how many messages generated.
I hope you had used multi mapping concept in mapping to generate multiple messages(by changing the occurrence to 0 to unbounded).
Receiver channel enable add time stamp option, so that you can differentiate files easily.
Regards,
Raj
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
91 | |
10 | |
10 | |
9 | |
9 | |
7 | |
6 | |
5 | |
5 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.