Multi-mapping based on content field

Hi guys,
I'm doing a scenario with mult-imapping 1x2, based on content field I'll create message1 or message2. If the source content has both key fields (ex. A = message1 and B = message2) the scenario works well, but if only one key field comes (ex. A to create only message1), an error occurs inside the transformation step of BPM. It seams BPM is waiting for message2 ...
(note: I'm using BPM because one of these messages is an IDoc)
Anyone has faced this issue?
Thanks in advance,
Ricardo.

Hi guys,
Thanks for the prompt answers.
I already have the occurrences with 0..1 (optional) and it doesn't work :s If I look into message mapping, I see that message1 and message2 are always 1..1 and there is no way to change it. In the messages tab you can only change the occurrence for the low level of each message1 or message2. Every time I test this mapping the header of message2 is always created even without content and that’s the problem and I don't know how to fix it...
Any ideas?
Thanks in advance,
Ricardo.

Similar Messages

  • Multi mapping and File Content Conversion

    Hi,
    I've created a similar interface to the the one in this blog
    /people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible
    In the Config, I receive a CSV and use FCC in the File Adapter to build the XML file. Because of the multimapping, XI adds the following to my Message Mapping
    <ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
       <ns0:Message1>
    Do I need to add this XML to the FCC??

    No,you dont need to add extra tags.
    Those tags are only for XI internal processing.
    Thanx
    Aamir

  • Content Field issue in Mail adapter receiver

    My  inerface CIDX->TO-->IDOC:
    I have an Error handling logic (Busines error) which needs to be send in EMail....the to address has to be detemined in runtime, the mail content is in the following format
    Mail Content:
    A KB order type came in from:
    Partner Information:
             Partner Name.
             Darex
             Chicago  IL 60638
             US
    ///below data till end  is for single line item, will occur twice if 2 line item
    PO Number       : 45012529631
    PO Line No       : 1
    Customer Product Code : YYYYYYY
    Customer Product Name : XXXXXXXXXX
    Price                    : 12345
    You should verify the PO is updated in the hosted solution and that the price is correct in SAP.  If this isn't the correct price from our partner please contact them and verify what the correct price should be.. 
    I am able to send the above content in mail for line item is 1, if there are more than 1 lineitem then it is breaking as mail content size is huge
    If there are Multiple Line items present in the Incoming CIDX file then the number od line items should be disaplayed in the mail. all the lines POLine NO till end will repeate for each Line Item....i am getting the arrayindex out of memeory exception as the data is huge which i am mapping to the content field of the reciver mail adapter....
    kindly suggest me the better method to handle this situation..my worry is if the number of line item is 10 then the mail content will be very huge and it will break during the runtime, as that field content cannot take so huge data.

    Hi Kiran
    Then there is no need to use Transformation bean for this
    In Mapping map the mail package Content_type field with
    text/plain;name="xyz.csv"
    and select mail package and keep attachments in receiver mail adapter
    This will work
    Thanks
    Gaurav

  • Multi-Message Mapping based on value of field - (Without BPM)

    Hi.
    I am having a bit of difficulty with multi-message mapping without BPM. I want to map to message1 & message2 based on a field in the rows of the source structure.
    e.g.
    row1-Source-Field1=> (if equal 0)   => <b>Message1</b>-field1.
    row2-Source-Field1=> (if equal 10) => <b>Message2</b>-field1.
    To attempt to do this, I use the conditions in the graphical mapper:
    if row-Source-Field1 = 0   => Map "Row to MessageType1".
    if row-Source-Field1 = 10 => Map "Row to MessageType2".
    However when I test this the mapping only seems to consider the first row value in row-Source-Field1 and ignores the fact that row two has a value of 10. I think this has something to do with contexts etc..
    I would appreciate any help please.
    Regards.
    Mick.

    in that case try this out
    row1-source-field1 (remove context) -- UDF -splitbyvalue-target
    UDF1(for message 1)
    for(int i=0;i<field1.length;i++)
    if(field1<i>.equals("0"))
    result.addValue(<field to be mapped><i>);
    UDF2(for message 2)
    for(int i=0;i<field1.length;i++)
    if(field1<i>.equals("10"))
    result.addValue(<field to be mapped><i>);

  • Spliting files based on condition using multi mapping with BPM

    Hi All,
    Can any one please let me know How to <b>Splite the outbound records based on condition using multi mapping with Integration Process in BPM</b>?
    Thanks
    Govindu.

    Hi All,
    Sorry for mistake this question for Exchange infrastructure guys.
    Thanks,
    Govindu

  • Multiple IDOCs based on multiple fields in File to IDOC mapping

    Hello Experts,
         I have a requirement to create multiple IDOCs based on multiple fields.
         Earlier my requirement is to create IDOCs based on ShipID (i.e., for every ShipID new IDOC...I achieved this).
         But now the requirement was to create IDOC based on two more fields like
    Source:
         ShipID1
         FieldA with value1 
         FieldB with value1
    Target :
         1 IDOC to create
    and If
    Source:
         ShipID1
         FiledA with Value2
         FiledB with Value2
         ShipID1
         FiledA with Value1
         FiledB with Value2
    Target:
         2 IDOCs based on FiledA
    Like wise IDOC should create for every change in FiledA and FieldB.
    If FiledA and FiledB has no changes then create IDOC based on ShipID
    please help me in achieving this as this is an urgent requirement.

    Hi Prasad -
    Just concat all the three fields - shipID1, FieldA and FieldB and
    remove contexts
    split by value (value changed)
    collapse contexts
    This way whenever there is a change in any of the above fields you'll have separate IDOC..

  • Multiple occurances of lin itm seg based on a field using graphical mapping

    Hi
    I have a scenario where in i have to populate the target segment multiple times based on quantity field LFIMG
    Source structure in IDOC and target structure is XSD. In the following we need to have multiple occurances of S_LIN based on LFIMG. So if the value of LFIMG is 6 we need to have 6 occurances of S_LIN.
    Source structure
    E1EDL24 (segment)
       LFIMG (field)
    Target structure
    ITEM (segment)
      GSHL (segment)
        S_LIN (segment)

    Hello Kalyan,
    You need to write an udf like this.
    LFIMG  (change context Queue)---->UDF ---> S_LIN
    Variable : source and separator(",")
    String[] values = source.split(separator);
    for(int i = 1 ; i < values.length ; i++){
         result.addValue(values<i>);
        result.addValue(ResultList.CC);
    Regards
    Pothana

  • Multi-Mapping, only want to create target messages sometimes.

    Hi,
    I have a Multi-Mapping interface which maps a single incoming message to 3 target messages.
    Based on the contents of the incoming message I only want to create a single instance of the outgoing messages.
    The incoming message can have a repeating node of 3 types A, B or C. If there are multiple nodes of Type A then i need to create a single instance of one of the target messages and map the data in node A to this message, likewise for node B and node C.
    I cant figure out how to do this. If I map a constant to the MT level of the target message and there are no type C nodes then the message type for this is created blank. But if I try and use the CreateIf tool then I get a MT created for each type C node.
    Can anyone help with this?
    If this isn't clear I will try to explain more.
    Thanks

    Hi,
    Thanks for your answer, I tried what you suggested and while it is creating the MT for type A nodes correctly it is not creating the MT for type B or C nodes. I have tried messing with the context on the incoming field and not getting anywhere.
    I always seem to get almost there with this mapping but never what I am looking for.
    Gareth

  • Multi Mapping with out BPM and Receiver Determination Condition

    Hi Masters,
    My Requirement Was:
    Proxy will send the data to XI system, Based Customer group number[1000,2000,3000,4000], I need to split the message into 4 messages, and sent to 4 Different location, based on Customer Group condition.
    For message split, I fallowed below weblog.
    /people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible
    Problem is file split correctly, but data goes to all customer groups..
    EX
    If they send the customer group 1000, I need to send the customer group 1000 file to BS1[Business Server1],
    If they send the customer group 2000, I need to send the customer group 2000 file to BS2[Business Server1],
    Please guide me,
    Thanks,
    ANU-

    Hi,
    Develope it like follow.
    Source Structure- Same for everything.
    Create 4 different structures for all targets, create 4 different msg types, 4 inbound message interface ( i think you are creating single Message type now, that is the mistake)
    In message maaping, add 4 target message types in same MM.. i hope i am clear..  ( same like in blog /people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible he has created 2 message types USER_1 and Employee)
    keep occurence of all of them 0 to unbunded (not necessary)
    Now create mapping for each message type (same like USER_1 and Employee, imagine them like different message types virtually). 
    Map message type with the source field and mention the condition which you want test using graphical functions.  i will say if x e equla to 1 creatif --> target.
    I hope i m clear till now...
    thanks.

  • Multi-mapping....2nd mapping not executing

    Hi all..
    I am doing Proxy to file scenario....
    I am using multi-mapping in this..
    one source..... 2 targets
    i am triggering the taregt based on a field value( using equalsS and IF)
    if i am testing it with single value then the mapping is success and fileds are bieng filled properlyy..
    but if i duplicate the subtree on source and put 2 conditions at a time...only first condition is executing and 2nd node is kept blank...
    i searched in SDn but no luck till now...
    plz help me out to solve this...
    Thanx in advance...

    thnax for the replies....
    i tried with SplitBy value but no use,....
    The structure...
    source:                                Target 1:          
    Root                                    Total_Males:          
      Name                                    Name
      Adress                                   City
      City
    Target2:
    Total_females:
       Name                                   
       Adress                                  
       City
    i am checking condition for "***' if it is male it will trigger first target1 .....female for target2.
    it is working with either male or female fine..
    but if i duplicate it and enter both male or female....only one condition i.e first i.e male is only triggering and 2nd is left blank..
    regards,

  • Multi mapping issue

    Hi ,
         I am using a multi mapping(with out bpm) in my scenario. One source structure is mapped to 3 different targets and these 3 different targets are using 3 different adapters.
      There will be a indicator from the source structure which descriminates all the 3 targets.
      How can I restrict the XI to send only to one target based on indicator in the source structure?
    EX: If the indicator in the source structure is 1000 then I want to send this message to only one target specified in the mapping.
    So my problem arises where in, because we are using multimapping 1:n, if I trigger a message in the proxy it will be sending to all the 3 targets. I don't want this.
    Appreciate your help on this.
    Thanks
    bpr

    HI
    You need to have 3 different channels for 3 receivers with receiver agreement for all three.
    Go to Receiver determination and under configured receivers you can specify condition you want.
    If the indicator in the source structure is 1000 then I want to send this message to only one target specified in the mapping.
    select the left operand as indicator field from source type
    = as Op
    right side is 1000
    Against this configure the receiver you want to send data.
    Thanks
    Gaurav

  • BPM multi-mapping

    Hi guys,
    I'm doing a multi-mapping in a BPM (I need the BPM for other validations). This multi-mapping is 1x2 and the messages are created based on payload fields(both are optional 0..1). the mapping is working fine, the problem is at the fork step, I've two send steps and whenever the message1 or 2 doesn't have occurences, I got an error that stops my BPM. But this is not an error as the messages are optional and don't need to occurs everytime.
    Anyone know how to solve this?
    Thanks in advance & regards,
    Ricardo.

    Hi Patreek,
    Necessary branches = 1.
    I already did it. It works if only one message is generated (message1 or message2). If both messages are generated I get no error at the BPM, but only one message arrives ERP and when I check at BPE moni one of the send steps is logical finished.
    Any idea? maybe I'm missing something...
    Regards,
    Ricardo.

  • Multi Mapping to multi receiver

    Hello all,
    I having a req that incoming IDoc hac multiple files say,
    <IDoc Name>
         <IDoc>
              <Field1>
              <Field2>
         <IDoc>
              <Field1>
              <Field2>
         <IDoc>
              <Field1>
              <Field2>
    Based on field 2 i need to send multiple receiver. For ex if my field2 is 10 i need to send receiver 1, if my field2 is 20 i need to send receiver 2, if my field2 is 30 i need to send receiver 3 and so on..
    I searched google and unable to get solution. Please help out of this. This is in high priority.
    Regards
    Amar

    Hi Amarnath,
    You can achieve your requirement in two ways.
    1)Multi mapping
    2)Enhanced receiver determination , (map b/w sender structure,receiver1 structure),(map b/w sender structure,receiver2 structure),...
    I personally prefer 2nd option because it looks very clean design and efficient than multi mapping.
    2)In enhanced receiver determination use the below udf.
    field2-->mapwithdefault-->remove context-->sort-->splitbyvalue (valuechange)-->collapsecontest-->udf-->receiver1,service1,receiver2,service2..............
    for(int i=0;i<n;i++){
         if(input[i].equals("10")){
              receiver1.addValue("");
              service1.addvalue("BSNAME");
    else if(input[i].equals("20")){
              receiver2.addValue("");
              service2.addvalue("BSNAME");
    In individual mappings just send those respective records
    field2-->mapwithdefault-->remove context-->equals("10")-->if-->mt_receiver1
    field2-->mapwithdefault-->remove context-->equals("20")-->if-->mt_receiver2
    NOTE:We need to go for either of the above approach because we need to check record in sender structure .
    Regards
    Venkat

  • Multi Mapping error

    Hi,
    I am required to have a IP recieve 3 IDOC types triggered from BD10 . It can trigger 3 or more IDOCs. For Eg.
    1 ARTMAS (only 1) , 2 INFRECs and 1 LIKOND.
    If anyone IDOC has come then after a waiting period of 1 minute it should come out of FORK.
    My IP is like this.
    In a FORK there are 4 branches.
    1) ARTMAS receiver
    2) Loop(infinite) with INFREC Receiver and a Container Operation to collect all IDOCs
    3) Loop(infinite) with LIKOND Receiver and a Container Operation to collect all IDOCs
    4) A wait Step with a container operation to initialize endtime variable
    necesary branches: 4
    The Fork Comes out when the end condition is met ie the End variable is Set or if all the IDOCS have  come.
    Corelation on MATNR.
    Next I have the transormation and send step.
    In the MM i have 3 Source and 1 Target.
    Artmas 0-1 occurance
    INFREC 0 - unbounded
    LINKND 0-unbounded
    I have created the Target with External Definition and have set the correct occurance in the XSD file
    I have mapped the neceessary Segments from INFREC and LIKOND and all the Segments of ARTMAS to the Target structure.
    In SXMBMONI it says error on Outbound side and
    I see Mapping Exception  when I seen in WORKFLOW.
    Is my design Correct?
    I have tested the Interface & Message Mapping they are correct
    Request your help.
    John Rajesh
    <?xml version="1.0" encoding="utf-8" ?>
    - <MappingTrace>
      <Trace level="1" type="T">Mapping-Namespace:http://test.com/usa/SapRetail/ARTICLE_CLASSIFY/TESTDEMO</Trace>
      <Trace level="1" type="T">Mapping-Name:IM_ARTMAS04_TO_ZARTMAS04_PUB01</Trace>
      <Trace level="1" type="T">Mapping-SWCV:00000000000000000000000000000000</Trace>
      <Trace level="1" type="T">Mapping-Type:JAVA</Trace>
      <Trace level="1" type="T">Mapping-Program:com/sap/xi/tf/_MM_ARTMAS04_TO_ZARTMAS04_PUB_</Trace>
      <Trace level="3" type="T">Multi mapping required.</Trace>
      <Trace level="3" type="T">Creating Java mapping com/sap/xi/tf/_MM_ARTMAS04_TO_ZARTMAS04_PUB_.</Trace>
      <Trace level="3" type="T">Load b8f12d30-2c45-11da-90af-ef160a892024, http://test.com/usa/SapRetail/ARTICLE_CLASSIFY/TESTDEMO, -1, com/sap/xi/tf/_MM_ARTMAS04_TO_ZARTMAS04_PUB_.class.</Trace>
      <Trace level="3" type="T">Search com/sap/xi/tf/_MM_ARTMAS04_TO_ZARTMAS04_PUB_.class (http://test.com/usa/SapRetail/ARTICLE_CLASSIFY/TESTDEMO, -1) in swcv b8f12d30-2c45-11da-90af-ef160a892024.</Trace>
      <Trace level="3" type="T">Loaded class com.sap.xi.tf._MM_ARTMAS04_TO_ZARTMAS04_PUB_</Trace>
      <Trace level="2" type="T">Call method execute of the application Java mapping com.sap.xi.tf._MM_ARTMAS04_TO_ZARTMAS04_PUB_</Trace>
      <Trace level="1" type="T">RuntimeException during appliction Java mapping com/sap/xi/tf/_MM_ARTMAS04_TO_ZARTMAS04_PUB_</Trace>
      <Trace level="1" type="T">com.sap.aii.utilxi.misc.api.BaseRuntimeException: RuntimeException in Message-Mapping transformation: Cannot produce target element /ns4:Messages/ns4:Message1/ZARTMAS04_PUB/IDOC. Check xml instance is valid for source xsd and target-field mapping fulfills requirements of target xsd at com.sap.aii.mappingtool.tf3.AMappingProgram.start(AMappingProgram.java:292) at

    Check the following
    1. Have u mapped the root level element?
    2. Inside interface mapping, when u say read interface, is it diplaying both the interface.
    Also check ur input
    may be u r not providing proper input
    Regards,
    Prateek

  • Duplicate Message ID issue in case of Multi mapping (without BPM)

    Hi Experts,
    I am doing one sample Example for my requirement of converting the single source message data into the multiple Target messages.
    for example, when sender system is sending the 5 sale order details into a single message in PI then my Inbound proxy class of ECC R/3 receiver system must get this sale orders separately, that means inbound proxy class method must be triggered separately for 5 sale orders from sender system. for achieving this, I have used the Multi mapping concept in ESR (without BPM).
    This scenario is in Asynchronous mode.
    The below screen shots give the details on what I have configures so far.
    IN ESR
    IN ID
    IN SXMB_MONI of PI
    IN SXMB_MONI of ECC R/3 Receiver system (Error in Processing)
    due to this error, inbound Proxy class method is not being triggered for the single Sale order details as well,
    please let me know how to tackle this duplicate message ID issue when we have multiple payloads to process in a single message.
    please also let me know if is there any other workaround to fulfil this requirement.
    Thank you,
    Regards,
    Jagesh

    Hi Nunu,
    Check the below blog for restrictions.
    Multi-Mapping without BPM - Yes, it’s possible!
    Restrictions
    Messages that result from the split in a mapping-based message split are sent using one AE. So only adapters running on the AE are supported. In particular, this means that target IDOC message splits are not supported since the IDOC adapter is not part of the AE.
    Regards,
    Praveen.

Maybe you are looking for

  • How Do I Find Out What Build Week My MacBook Is ?????

    Hi People, i was just wondering if anyone could help me find out what build week my macbook is as some people are having problems with there macbook and they are saying it has something to do with the build week my macbook will be a week old on the s

  • Function in update task goes to dialog process(seen by sm50)

    Hi Forum,    I wrote a simple test to invoke a function module in update task, and the execution of the module takes several minutes (updating database using opensql) . The test looks simply like described in the following link: http://www.**********

  • Directory properties in java.io.*

    I know I can check if a directory exists with the .exists method, but I want to know if the directory contains anything. Is there any built-in method for this? If a built-in method doesn't exist, I'm thinking that I would have to use the .length of t

  • Property binding of a dynamic UI element

    Hi all, It is no problem to define property binding of a UI element statically (see [Example|http://wiki.sdn.sap.com/wiki/display/WDABAP/SimpleapplicationtochangepropertiesofUIElementsduringruntimeinWebDynpro+ABAP]) But, how can I define property bin

  • FND_REQUEST.SUBMIT_REQUEST

    Dears, can I control layout format of FND_REQUEST.SUBMIT_REQUEST ??? can I get .rtf layout instead of .pdf format ?? please help Edited by: [email protected] on Feb 2, 2009 8:22 AM