BPM SAP Pattern BpmPatternCollectMessage

Hello All,
I test the SAP BPM Pattern BpmPatternCollectMessage. All works fine but I have a question:
In a parallel section are two receive steps, one for the business messages and one for the stop message.
The business receive step activates the correlation.
If due tue an error the stop messages was processed first then an queue error stop the bmp process, because there is no active correlation.
how to fix this so stat an error is thrown in bmp and not on queue level
regards
ralf

The pattern has two receive steps. But the "Start Proces" is checked only for the original message and not the Termination message. If you want to handle things in BPM, you need to accept the stop message by activating the BPM instance even if the Stop message is sent first. So you may check the Start Process for other receive step also and then based on some condition, raise some exception.
Regards,
Prateek

Similar Messages

  • BPM Collect Pattern Scenario :Container is empty for the loop at run time

    Hi Friends,
    I am working on BPM Collect Pattern Scenario after looking into the example delivered by SAP in namespace http://sap.com/xi/XI/System/Patterns and IP name as BpmPatternCollectPayload.
    After configuring the same and when it is run, I see strange behaviour as illustrated below
    1. Container step is empty and not able to see the counter for which it needs to be incremented at runtime
    2. I understand that Loop should start and it need to be incremented as when we get a new message into the same BPM.
    But I observe that it is creating a new message and loop never stops and completes the condition and comes out to go to next step.
    Request your help.
    Regards,
    Hussain

    Hi,
    define or declare a variable with name counter and type as integer in Container where you define abstarct variables...
    Thanks,
    Madhu

  • BPM Collect Pattern:File to IDoc

    Hi,
    My scenario is File to Idoc. An invoice excel file will be sent by the vendor.The excel has a built in macro, which converts the excel to a csv file and file is placed in a file share server.
    *Logic of Macro: *
    There will be a button in the excel file containing macro. In one excel file there would be multiple invoices that contains different number of item lines, The macro checks the u2018Invoice Numberu2019, lines with the same invoice number will be saved in one CSV file. So for example a excel file contains 5 invoices, when press the button that contains the macro, there will be 5 CSV files created under the same path, each CSV file contains one invoiceu2019s information.
      After this I have to post the Inovices in to SAP using an IDoc.
    So, I am using BPM collect pattern to achieve this. In the collect pattern,  I see a correlation defined on one of the source fields,  What does correlation exaclty do in my  case. Let's say I have defined a correlation on Source field called Invoice number.
    BTW I am using FCC on the filed adapter to change the CSV(Invoice) to xml
    Thanks,
    Kiran

    Hi
    to use Xpath for your receiver det. ref these blogs;
    a combination of logics should help you in this case ...
    Customise your 'XPATH' Expressions in Receiver Determination
    XPath to show the path (Multiple Receivers)
    File to Multiple IDocs (XSLT Mapping)
    Try removing BPM from ur scenario.
    1:n could be achieved without BPM
    Various multi-mappings and Optimizing their Implementation in Integration Processes (BPM) in XI.
    Regards,
    Suryanarayana

  • BPM design pattern

    can any provide information on BPM design pattern and give examples scenarios.
    thank you

    hi vicky,
    check this links
    Design Patterns in Exchange Infrastructure
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/f0ad6de0-7cd6-2910-f894-dd7fe18b6fbf
    BPM with Patterns explained Part-1
    regards
    reddy

  • How many Communication Channels required for File--Bpm(SAP R/3)--File

    Hi
        Pl..help me on this
        I am doing the following scenario File 2BPM 2 File
        i.e File -
    BPM(ASync)
            BPM -
    SAP R/3(Sync)
            SAP R/3 ---BPM (Sync)
            BPM ---File (Async)
        For me it looks three CC's  but still i am not confident
        Can any one explain me on this
    Adv thanx
    Prasad K

    File(<b>CommChannel 1 -File Sender</b>) -
    > BPM(ASync)
    BPM -
    > SAP R/3(Sync) (<b>CommChannel 2 - RFC Receiver</b>)
    SAP R/3(Comm Channel 3 -RFC Sender) --- > BPM (Sync)
    BPM ---> File (Async)(<b>CommChannel 4 - File Receiver</b>)
    <i><u><b>So a TOTAL of 4 Comm Channels.</b></u></i>
    Since Sinchronous so 4 channels .. if you use idoc adapter instead of RFC 3 channels will do
    Cheers,
    Himadri
    null

  • BPM collect pattern based on payload

    Hi,
    i am doing BPM Collect pattern based on stop message which is RFC. Means, i need to collect the IDOCs until i get the RFC from another system.
    For this i am using predefined pattern BPMcolllect pattern which is in BASIS SWCV.
    is it possible to do with out correlation?
    if correlation is required, there should be one common fiield between two messages?
    Thanks,
    karthik

    Hi ,
    Your design it self wrong, when you develop interface as a sender IDoc , then how come you will receive RFC in to BPM??
    so check your requirement with your client, if you want to collect messages there are different ways, implementing patterns in last option.
    search in sdn.
    Regards,
    Raj

  • Interface Mappings in BPM Collect Pattern

    Hello
    I am new to XI development and currently facing problems while implementing collect pattern of BPM.
    I am trying to map IDoc structure with target legacy format.In BPM I had a block with infinite loop where I am transforming IDocs to target legacy format.Then I am trying to transform list element (Multiline Abstract container variable) to form a single message.For this I tried to have interface map with Occurences 0..unbound..but while activation of Interface Map it gives error
    <b> Mapping program Message does not match the interface mapping. The number or frequencies of source or target messages for the message mapping are not identical to the number or frequencies of source or target interfaces.</b>
    If I use single line in Interface map then in BPM it gives error when passed Multiline element to this Interface map.
    I checked the sample program provided by SAP but I found out that every message interface was using same Message Type which has got occurence as 1 but in the message mapping program its 0..unbound.
    My question is can we have data type (or Message type )with Occurence as 1 and Message Mapping program using same message type with occurences 0..unbound..I tried to find such option but could'nt find that.Otherwise how to do Interface Map for transforming Multiline parameter of BPM to a single message.
    Please help..Thanks in advance..
    Regards
    Rajeev Patkie

    Initially I tried to perform test by tree view and it worked fine.But it was one message in the source and the same was in target.Later as given by you I updated XML source message.The source message looks like
    ******************Source Message***********************
    <ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
      <ns0:Message1>
        <ns1:MATMAS_to_Stockware_MT xmlns:ns1="http://mccormick.com/ez_dev">
          <MAT_List>
            <ZPITNO>121212</ZPITNO>
            <ZPIDS>Test Message</ZPIDS>
            <ZPPOPN />
            <ZPCNQT />
            <ZPZLOC />
            <ZPZPCB />
            <ZPZCPA />
            <ZPGRWE />
            <ZPSAEL />
            <ZSPLDY />
            <ZPFRAG />
            <ZPZCRO />
            <ZPZOPT />
          </MAT_List>
        </ns1:MATMAS_to_Stockware_MT>
      </ns0:Message1>
    </ns0:Messages>
    <ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
      <ns0:Message2>
        <ns1:MATMAS_to_Stockware_MT xmlns:ns1="http://mccormick.com/ez_dev">
          <MAT_List>
            <ZPITNO>78912</ZPITNO>
            <ZPIDS>Test Message12</ZPIDS>
            <ZPPOPN />
            <ZPCNQT />
            <ZPZLOC />
            <ZPZPCB />
            <ZPZCPA />
            <ZPGRWE />
            <ZPSAEL />
            <ZSPLDY />
            <ZPFRAG />
            <ZPZCRO />
            <ZPZOPT />
          </MAT_List>
        </ns1:MATMAS_to_Stockware_MT>
      </ns0:Message2>
    </ns0:Messages>
    ************************End Source*********************
    if this would be the message multiline is generating its bound to fail as I guess every XML has one topmost element and over here.So I changed my source XML to look like
    ******************Start message******************
    <ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
      <ns0:Message1>
        <ns1:MATMAS_to_Stockware_MT xmlns:ns1="http://mccormick.com/ez_dev">
          <MAT_List>
            <ZPITNO>121212</ZPITNO>
            <ZPIDS>Test Message</ZPIDS>
            <ZPPOPN />
            <ZPCNQT />
            <ZPZLOC />
            <ZPZPCB />
            <ZPZCPA />
            <ZPGRWE />
            <ZPSAEL />
            <ZSPLDY />
            <ZPFRAG />
            <ZPZCRO />
            <ZPZOPT />
          </MAT_List>
        </ns1:MATMAS_to_Stockware_MT>
      </ns0:Message1>
      <ns0:Message2>
        <ns1:MATMAS_to_Stockware_MT xmlns:ns1="http://mccormick.com/ez_dev">
          <MAT_List>
            <ZPITNO>78912</ZPITNO>
            <ZPIDS>Test Message12</ZPIDS>
            <ZPPOPN />
            <ZPCNQT />
            <ZPZLOC />
            <ZPZPCB />
            <ZPZCPA />
            <ZPGRWE />
            <ZPSAEL />
            <ZSPLDY />
            <ZPFRAG />
            <ZPZCRO />
            <ZPZOPT />
          </MAT_List>
        </ns1:MATMAS_to_Stockware_MT>
      </ns0:Message2>
    </ns0:Messages>
    **********************End Message****************
    but this produces only one output message
    ******************Start Message***********************
    <?xml version="1.0" encoding="UTF-8"?>
    <ns0:Messages xmlns:ns0="http://sap.com/xi/XI/SplitAndMerge">
      <ns0:Message1>
        <ns1:MATMAS_to_Stockware_List xmlns:ns1="http://mccormick.com/ez_dev">
          <MAT_List>
            <ZPITNO>121212</ZPITNO>
            <ZPIDS>Test Message</ZPIDS>
            <ZPPOPN />
            <ZPCNQT />
            <ZPZLOC />
            <ZPZPCB />
            <ZPZCPA />
            <ZPGRWE />
            <ZPSAEL />
            <ZSPLDY />
            <ZPFRAG />
            <ZPZCRO />
            <ZPZOPT />
          </MAT_List>
        </ns1:MATMAS_to_Stockware_List>
      </ns0:Message1>
    </ns0:Messages>
    **********************End Message****************
    I am also pasting schema of message mappings
    *****************Source Schema************************
    <?xml version="1.0" encoding="UTF-8"?>
    <xsd:schema targetNamespace="http://sap.com/xi/XI/SplitAndMerge" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://sap.com/xi/XI/SplitAndMerge">
      <xsd:import namespace="http://mccormick.com/ez_dev" />
      <xsd:element name="Messages" xmlns:p0="http://mccormick.com/ez_dev">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element name="Message1" form="qualified">
              <xsd:complexType>
                <xsd:sequence>
                  <xsd:element ref="p0:MATMAS_to_Stockware_MT" minOccurs="0" maxOccurs="unbounded" xmlns:xsd="http://www.w3.org/2001/XMLSchema" />
                </xsd:sequence>
              </xsd:complexType>
            </xsd:element>
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:schema>
    ********************End Source***********************
    ********************Target Schema******************
    <?xml version="1.0" encoding="UTF-8"?>
    <xsd:schema targetNamespace="http://sap.com/xi/XI/SplitAndMerge" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns="http://sap.com/xi/XI/SplitAndMerge">
      <xsd:import namespace="http://mccormick.com/ez_dev" />
      <xsd:element name="Messages" xmlns:p0="http://mccormick.com/ez_dev">
        <xsd:complexType>
          <xsd:sequence>
            <xsd:element name="Message1" form="qualified">
              <xsd:complexType>
                <xsd:sequence>
                  <xsd:element ref="p0:MATMAS_to_Stockware_List" />
                </xsd:sequence>
              </xsd:complexType>
            </xsd:element>
          </xsd:sequence>
        </xsd:complexType>
      </xsd:element>
    </xsd:schema>
    ****************************End Target*************
    Thanks in advance.
    Regards
    Rajeev

  • BPM Collect Pattern: N:1 Mapping error in trnsformation step

    Dear All,
    I am using collect pattern Payload Dependant.
    I have one source data type and one target data type. Mapping is one to one.
    Data type contains 3 fields, Value Name and Surname.
    In Loop I have used condition when Counter is equal to value stop the loop.
    I have used Transformation step as I am using N:1 mapping.
    I have used abastrct to abastract message mapping.
    Source message is 0 to unbounded.
    In interface mapping target message occourance is 1. But in mapping program target message occourance is 0 to unbounded.
    When I am running my scenario, Third party to IP is working fine. But in IP i am getting error in transformation step.
    "com.sap.aii.utilxi.misc.api.BaseRuntimeException: RuntimeException in Message-Mapping transformation: Cannot produce target element /ns0:Messages/ns0:Message1/ns1:Collect_Receiver_MT. 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"
    Can anybody will help me to solve this problem?
    Warm Regards,
    Gouri

    Have a look
    http://help.sap.com/saphelp_nw04/helpdata/en/de/766840bf0cbf49e10000000a1550b0/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/cb/15163ff8519a06e10000000a114084/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/08/16163ff8519a06e10000000a114084/content.htm
    /people/sudharshan.aravamudan/blog/2005/12/01/illustration-of-multi-mapping-and-message-split-using-bpm-in-sap-exchange-infrastructure
    /people/kannan.kailas/blog/2005/12/07/posting-multiple-idocs-with-acknowledgement
    Also have a look at these seminars,
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/media/uuid/daea5871-0701-0010-12aa-c3a0c6d54e02
    https://www.sdn.sap.com/irj/servlet/prt/portal/prtroot/docs/media/uuid/e8515171-0701-0010-be98-e37bec4706cc
    Thanks

  • BPM Collect pattern is not coming out  and it is in loop.

    Hi Experts,
    We have implemented a BPM Collect Time pattern and it was working fine in Dev and QA environments perfectly. Couple of days back we have some server issue in Dev environment and Basis team has done some thing with File Storage. From that time, all our BPM's were not working in Dev. It is showing that the block is waiting for some event to trigger and it is in Process state.  We have set it for 5 min and block is not coming out from loop.   We exported the code to QA and it is working in QA.  We tried SWU3 transaction as given in the below forum and it didn't help us.
    bpm collect time infinite loop error
    Some one please help us.
    Thanks
    Venkat
    Edited by: Venkata Gupta on Nov 27, 2008 12:54 AM

    Hi
    Is Your BPM having deadline branch ?
    If there is any system Exception then catch it.
    http://help.sap.com/saphelp_nw04/helpdata/en/33/4a773f12f14a18e10000000a114084/content.htm.
    According to thread mentioned by you ,Schedule your Missed Deadline Branch.
    Also check your BPM using transaction SXMB_MONI_BPE and find out which step have error.

  • BPM Collect Pattern.

    Hi Experts !
    I am trying to implement this scenario.
    Source File Adapter -
    Message - Vendor # - Material # [Only one material ]
    Pattern : Collect Pattern
    Key for Correlation - Vendor #
    Message collection in Loop for a counter of 3 Messages.
    Target file on Directory to be created using file adapter should be of this structure:
    <Header> 1.1
    vendor
    <Header/>
    <Items> 1..Unbounded
    <Material>Matl1 <Material/>
      <Material>Matl2<Material>
      <Material>Matl3<Material/>
    <Items/>
    When collect messages into a multiline container it will be based on source message.  The multiline container will be looking like this:
    vendor# Material#
    vendor# Material#
    vendor# Material#
    after all the three records are collected.
    What mapping from this point is required to get the output explaine above.
    Please mention whether it is a step outside BPM or inside BPM.
    When system encounters a multiline container does it process each message at a time or is the mapping applied to all the messages at a time.
    Thanks in advance..

    Thanks for sharing your views.
    As I mentioned I will stop collection based on a counter.
    Coming to my question again..
    N : 1 Mapping..
    Can you elaborate on N:1 mapping you are suggesting.
    Here is what I did ..
    One Msg...   -
    >         Multine Line                           Mapping
    abs                          similar to One msg          source                target
                                                                        multiline abs        target_abs..
    Message Mapping details...this is what i use in Intf.Map..aplied above.
      vendorx         -
    > VendorX
      material1 1.1 -
    > Material [1..n]
    where the output I get is only the last item processed...
    If I pass                                       Output
      Vendor1 - Matl1                       Vendor - Matl3....
      Vendor1 - Matl2
      Vendor1 - Matl3
    Where am I going wrong...
    thanks.

  • Necessary steps for incorporating BPM collect pattern?

    I am working on my first BPM.
    The scenario is as follows: Supplier information (CREMAS) has to be splitted into their respective receiver countries (This has been done with a switch) For each country all CREMAS has to be collected into one XML and sent.
    I have decided on BPMCollectPatternTime.
    What should I do in order to include a CollectPattern in my BPM?
    What design objects should I copy to my namespace?
    And how to configure receive, loop and transformation?

    Hi Thomas,
    So you are sending multiple CREMAS IDocs to SAP XI and you want a BPM to collect the IDocs together into separate XML messages by country.
    In this case you dont need a switch statement, just use a time based collection routine and a correllation on the country field.
    We have used this method extensively, you want to choose how to terminate the BPM. You can set up an infinite loop scenario with a time based termination via a deadline branch.
    In order to use this in your own BPM create the Integration Process and add the following steps in the editor, this will aid you in understanding the various steps and how the process works.
    You will need 3 Abstract Message Types:
    1) Single IDoc Message Type
    2) Multiline IDoc Message Type for Appended IDocs
    3) Non Multiline IDoc Message type for the List of collected IDocs
    First add a block step
      Mode = Default
      Local Correlation = Define Correlation on Country
    Within the block step:
    Deadline Branch = 1 minute for example
      Control step = Throw Exception
                          |
    Main Branch = boldLoop Step Beginbold --- Receive Idoc Step --- Container Operation --- boldLoop Step Endbold
    Loop Step
      Condition = (1 = 1)
    Receive Step
      Message = Abstract Message Interface
      Use Correlation = Local Correlation
    Container Operation
      Operation Append
    Outside the block step:
    Transformation Step
    Send Step
    Hope this helps,
    Pete

  • BPM - SAP netweaver 7.3

    Hi Folks,
    I overheard about the  BPM integration with SAP NetWeaver Administrator 7.3. Have you guys already configured it? Do you have more information about it, as instance: oss notes, documentation, cookbook and etc..?
    thank you so much

    Hi Tushar,
    Have you checked out the standard documentation? It shows how to configure mandatory components and capabilities like BPM....
    http://help.sap.com/saphelp_nw73/helpdata/en/4b/f39625e7d13c6de10000000a42189c/content.htm
    O.

  • BPM collection pattern - Expression must not return a multiline value

    Hi,
    I am trying to create an integration process to collect messages - when I run the check function I get the message 'Expression must not return a multiline value' - I have checked everything and cannot find what is causing this message.  When I click on the message I get taken to the transformation step properties.
    Any ideas?
    Regards
    Ian

    HI,
    Your Interface Mapping should be of N:1 type.
    i.e occurence of your source message should be of 0..unbounded and target message should be 1.
    Once you change Interface Mapping, you need to change occurences of corresponding Message Maaping.
    Use this interface mapping in your Transformation Step in BPM, where you collect all the messages.
    Hope this helps,
    Regards,
    Moorthy

  • Error / BUG in BPM SAP PI7.1 "Expression must not return a multiline value"

    Hey experts,
    I try to use a MULTILINE interface in an integration process, but when I try to select the multiline interface in the sending Step (asynch), then I can´t select a INDEX variable? ...
    See here: Picture of ERROR
    I tried my steps with a XI3.0 in exactly the same way and it works. Is this a bug in the PI? We have Service Package 04 (initial Shipment).
    Does anyone has an idea?
    Thanks a lot for fast help
    Rgds,
    Steffen

    Hi,
    I tested it on a PI 7.1 SP 8 and there it works.
    What you could try is to export your Integration Process from XI 3.0 (you said it's working) and import it in your PI 7.1.
    Regards
    Patrick

  • BPM Integration Process that correlates 2 messages.

    I have an BPM Integration Process defined that collects Deliveries for an Order number and when an Invoice arrives for the same Order number it merges the messages to produce another file that is for a 3rd party.
    I correctly receive in the Delivery and the Invoice u2013 I can see them in SXMB_MONI with a checkered flag and they are directed to my BPM.  I can see this also in SXMB_MONI_BPE.  I can also see the correlation correctly found in both messages.  No error is reported by either SXBM.. transaction.
    However it does nothing except receive the files u2013 I am expecting a transformation and then the send step to execute.
    Start >  CollectIDOCBlock  > Collect Fork
    Fork1
    Infinite Loop for Receive Delivery (Start process) and Collect in Container. It uses and activates Correlation OrderNum
    Fork2
    Receive Invoice uses Correlation OrderNum (it does not activate the correlation)
    At the end of the Fork (when Delivery collected and an Invoice is received)
    It will then do the Transformation and Send Step.
    <End
    I have tried various combinations of the correlations and which receive step starts the process.  Any ideas ?

    Yes that did work.  Now does somebody know what exactly the FORK parameter number of branches does ?
    The SAPHelp is here
    http://help.sap.com/saphelp_nw04/helpdata/en/08/16163ff8519a06e10000000a114084/frameset.htm
    +You can specify the required number of branches and then define whether the process must run through all branches, or just a particular number of branches+
    But it does not explain why you need to have 1 as necessary branches rather than 2.  There are 2 branches in the FORK - so why does having 1 as the parameter work and not 2.
    In this SAPHelp for Message-Dependent Loop
    http://help.sap.com/saphelp_nw04/helpdata/en/08/16163ff8519a06e10000000a114084/frameset.htm
    it indicates to me that the parameter should be 2.
    BUT the SAP pattern (BpmPatternCollectMessage) I have used as a base for mine has this as 1 and not 2.
    Why is 1 the correct value and not 2 ??

Maybe you are looking for

  • GetFirstFile() and non-english chars

    Hi, When using GetFirstFile() / GetNextFile(), if a file is encountered with Chinese chars in it's filename, each of these chars is replaced with a "?". As a result, I cant open the file as I dont know its full name. Does anyone know of a way around

  • Using Apple Remote Desktop's VNC service with a Windows Machine

    I have the latest ARD version. I have a VNC service running on my Windows machine. I know I can manually add the Windows machine to ARD. when I highlight the Windows machine in the 'All Computers' window and click Control, will ARD be able to connect

  • Mail Auto Retrieval - Nokia 5800

    Hi, Im having a problem with Nokia's Email App on my 5800XM. I just set up 3 mail accounts, but i can configure automatic retrieval only for 2 of them. Is it limited just for 2 account (auto retrieval)? Is there any way to increase this value?. Hope

  • Identify TAX condition type from pricing procedure

    Hello, I need to identify Tax condition type for various countries used in Old sales orders.We are moving to an external Tax engine and I need to identify what condition are being used to calculate tax in various countries. I know the pricing procedu

  • Connecting External WebServices

    Hello All: I am trying to connect external webservices, but running into same issue time and again. When running a testcase, the result produces is as below. I am trying to connect to a free on the internet currency converter webservice at www.webser