X-path expression in Receiver determination

Hi,
I am working on JDBC to SOAP interface using BPM in PI7.0.
I am trying to use the XPath function in creating a condition in my receiver determination to route messages to two different business systems. My issue is that i could not find the JDBC message structure in x-path expression.
Any one please can help me on this.
Thanks In Advance!

Hi,
     For x-path expressions in the receiver determination, you would not be able to choose the sender structure fields like you would do normally. You would have to provide the x-path manually, starting from the root node upto the required field.
Regards

Similar Messages

  • Reg:'XPATH' Expressions in Receiver Determination

    Hi All,
    My scenario is an IDoc type.
    Structure:
    ZABCD
    IDOC
    TEST1
    FIELD1
    FIELD2
    TEST2
    FIELD3
    FIELD4
    Condition:
    (field1 = "500" OR field1 = "800" ) AND (field3 = "EZTU" OR field4 = "BLKB")
    I am trying to achieve the above condition  through own XPATH expression in Receiver determination.
    Can anyone help me out in this.
    Thanks in Advance,
    Lavanya .B

    I have just simulated your structure in XML Spy
    <ZABCD>
         <IDOC>
              <TEST1>
                   <FIELD1>500</FIELD1>
                   <FIELD2></FIELD2>
              </TEST1>
              <TEST2>
                   <FIELD3>EZTU</FIELD3>
                   <FIELD4>BLKB</FIELD4>
              </TEST2>
         </IDOC>
    </ZABCD>
    and the XPath is /ZABCD/IDOC/TEST1[FIELD1 = '500' or FIELD1= '800' and /ZABCD/IDOC/TEST2[FIELD3 ='EZTU' or /ZABCD/IDOC/TEST2[FIELD4 = 'BLKB'
    consider that thread does not show the some character, so, put a ] after 800,'EZTU' and 'BLKB' if i put it the blog consider as a link everithing between [     ]
    I mean
    '800']
    'EZTU']
    'BLKB']
    refer to this link: /people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination
    Edited by: Rodrigo Alejandro Pertierra on Sep 15, 2010 10:46 AM
    Edited by: Rodrigo Alejandro Pertierra on Sep 15, 2010 10:49 AM

  • Using substring in the XPATH expression for Receiver Determination

    Hello, I need a little help please.  In my receiver determination, I have a condition and I need to do a "not like" check.   Basically, if the first three positions of the source field does not start with a specific code, then I need to execute the condition.   The condition editor does not support a "not like" operand, so I went to the XPATH expression editor.  I tried to used the XPATH substring function to get the first three characters and then do a "not equal" operand, but it doesn't appear to work.  There are not any runtime errors, but the condition is not executing.  Any ideas on this?  Does the XPATH expression support the substring function?

    Hi Jesse,
    Can you please explain what is the meaning of http:// in the statement
    /p1:PRODUCT/MATNRhttp://not(substring(.,string-length(.) - 2) = '123')
    Please explein, I am having same issue. It is not working here.In My case it is
    /p1:ORDERS01/IDOC/E1EDP01/E1EDP19/IDTNR[http://not(starts-with(.,\"D\"))]
    also tried with
    /p1:ORDERS01/IDOC/E1EDP01/E1EDP19/IDTNR[http://not(starts-with(.,'D'))]
    Thanks in advance!

  • Condition "not containing" expression  in Receiver Determination

    Hi guys,
    I have one interface which processes files with lines compossed by two fields, an identificator, and a data field.
    Inside the data field, i have a row of characters and I want to create this condition in the receiver determination:
    If Data contains text "e6212" then, receiver is X
    If Data does not contain text "e6212" then, receiver is Y.
    I know how to create the first condition, but not the second. Could anybody help me? Thanks in advance!

    Hi,
    The condition editor contains 'Contains Pattern (CP)':
    You use this operator to query a string with a pattern. You can use the following characters for this:
    ·        + for any single character
    ·        * for any string
    *mploymenttaxdeclarat+on annualemploymenttaxdeclaration.
    please read more here:
    http://help.sap.com/saphelp_nw04/helpdata/en/67/49767669963545a071a190b77a9a23/content.htm
    regards
    Vijaya

  • Xpath expression in Receiver Determination

    Hi All,
    I have a condition where i need to check if WERKS is containg any value starting with IT , then i need to send this IDOC to the target.
    I tried to used the following expression \MARCM\WERKS = IT* in RD , but its not workin when i am sending an IDOC with value as IT03 or other values startign with IT .
    Any idea how to deal with such an issue...
    Regards
    Vinay P.

    Hi,
    Instead of
    \MARCM\WERKS = IT*
    Use
    \MARCM\WERKS ~ IT* 
    [dobule(~)]
    double(~)
    for your help
    http://wiki.sdn.sap.com/wiki/display/XI/XpathConditioninReceiverDetermination
    regards
    Ramesh

  • Receiver determination - Xpath expression problem with count

    I am working with a scenario where I pick up records from a JDBC connection and if the number of records I pick up is less than a certain number I want to call a webservice.  If it is greater than the number I want to write out a file to be processed by a different process on the receiving end.  I have created the receiver determination condition with the following conditions:
    (/p1:MT_HOG_Data/row[count(row) > 3] EX)
    (/p1:MT_HOG_Data/row[count(row) <= 3] EX)
    The integration is always processing the second condition no matter how many records come in.  I have tried with and without the multiline option.  Can anyone help with this?
    I have searched through the forum and checked the following links without any resolution:
    http://wiki.sdn.sap.com/wiki/display/XI/XpathConditioninReceiverDetermination
    http://help.sap.com/saphelp_nwpi71/helpdata/EN/ab/13bf7191e73a4fb3560e767a2525fd/frameset.htm
    /people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination
    I can't find any examples where a count of records is checked in the expression editor.  Thanks in advance for any help.

    You can not use the EX operator in that case, because that is used only for node existence checks, not for value checks.
    Do you have a row number in your structure ? Then you could write the xpath expression with that counter tag and value
    Example: you want to send to receiver A if count > 3, else to B:
    you set  /rowNumber EQUAL 4 for sender A
    and /rowNumber NOT EQUAL 4 for sender B
    The condition is applied to the whole document. If one of the node/values are true for that condition, then the whole condition is set to true.
    Problem with that is that the second condition also will be true because nodes for that condition will be found
    better would be to have a rowcount tag in the structure. If that is not possible, you can use the "Enhanced Receiver determination" where you can define a mapping which determines the receivers. There you can do anything complicated you want.
    CSY

  • Content based routing in receiver determination.

    hi,
            how to do content based routing in receiver determination based on value of  of a variable of target structure?
    Miten.

    ths is what you are looking for
    /people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination
    /people/shabarish.vijayakumar/blog/2005/08/03/xpath-to-show-the-path-multiple-receivers

  • XPATH condition in receiver determination.. Sum one of the filed

    Hi,
    This is my input payload.
    segment "Record" will be coming multiple times.
    <ns:MT_Account xmlns:ns="urn:com.statement">
    -<BalanceRecs>
      - --<Record>
    <field1>CUA</field1>
    <field2>0.00</field2>
    <field3>324612.28</field3>
    <field4> LTD</field4>
        -----<numRecs>0</numRecs>
    </Record>
      --- <Record>
    <field1>CUb</field1>
    <field2>0.00</field2>
    <field3>324612.28</field3>
      <field4> LTD</field4>
      <numRecs>2</numRecs>
    </Record>
      --- <Record>
    <field1>CUc</field1>
      <field2>0.00</field2>
    <field3>324612.28</field3>
       <field4> LTD</field4>
    <numRecs>0</numRecs>
      </Record>
    </BalanceRecs>
    Requirement:
    I need to calculate the sum of field "numrecs".
    If the sum is 0, then pass to BPM(IP_BPM)
    If the sum is > 0 then pass to System B.
    I tried using the below blog from shabarish..
    /people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination
    /p1:MT_ActBalance/BalanceRecs/BalanceRecord[sum(numRecs) = 0] EX        --> BPM
    /p1:MT_ActBalance/BalanceRecs/BalanceRecord[sum(numRecs) > 0] EX        --> SystemB
    Is there anything im missing .. kindly suggest.
    Thanks
    Deepthi.

    Hi Mark,
    It is working only for one receiver.
    i mean
    <numRecs>0</numRecs>
    <numRecs>0</numRecs>
    <numRecs>0</numRecs>
    The message is going correctly when the sum value is 0. ie to BPM.
    <numRecs>0</numRecs>
    <numRecs>2</numRecs>
    <numRecs>0</numRecs>
    OR
    <numRecs>2</numRecs>
    <numRecs>0</numRecs>
    <numRecs>0</numRecs>
    When I pass the above payloads, it is going to both the receivers.
    Since the total is 2, it should go only to systemB
    Any idea?
    This is working perfectly for enhanced receiver determination. I dont want to use enhance version for this simple case.

  • Receiver Determination - condition editor

    Hi,
    I have a receiver determination which receives files and the filename determines where the file is sent/routed. I am using the condition editor for this functionality and need some help. The filename contains the following format 'xxxxxx010xxx20070101.out' where xxx represents different codes depending on the extraction. I used the following in the condition editor:
    ++++++010* I understood each + to represent a character. This is not working, any ideas?
    Thanks,
    Leanne

    you can utilize XPATH functions in your conditions to acheive the same.
    Try to take the help of the following weblog and maybe the string functions of xpath to achieve your results.
    ref:
    /people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination
    http://www.w3schools.com/xpath/xpath_functions.asp#string

  • Receiver Determination conditions

    Hi All
    We have a scenario where a IDOC is trigerd in the ecc system and multiple IDOC is send to the XI system. Only when a certain field is 3  char or 5 char or 7char long should the file be dumped on the server. Is is possible to have a condition in the receiver determination to say if the field is between 100 and 999 or between 10000 or 99999 or between 1000000 and 9999999 to only create the files?
    Any help will be appreciated.

    hi,
    Its quite easy to achieve this requirement.
    You can edit the xpath in the Recv. Determination and then in combination with xpath standard functions achieve this.
    have a lo0k at my blog - Customise your 'XPATH' Expressions in Receiver Determination
    Also for xpath functions ref: http://www.w3schools.com/Xpath/xpath_functions.asp

  • Customizing XPATH in Receiver Determination

    Hello,
    I am using this blog to write conditions /people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination and accordingly call the receiver (either Receiver_1 or Receiver_2), never to call both the receivers simultaneously
    I have a sample source message like:
    <?xml version="1.0" encoding="UTF-8"?>
    <ConsumerDetails>
       <UserId>91200024:123456</UserId> To check if UserId starts with 91200024: or not
       <Date>20111301161459</Date> To check if length of Date is 14 or not
       <Billing>RC</Billing> To check if Billing has value RC/ SB or not
       <Type>SE</Type> To check if Type has value SE/ CWE or not
    </ConsumerDetails>
    Accordingly wrote the below conditions:
    Receiver_1 (Conditions working fine):
    UserId (MiddleOperator --> ContainsPattern) --> 91200024:*
    /ConsumerDetails[(string-length(Date)) = "14"] --> EX
    /ConsumerDetails[(Billing = "RC") or (Billing = "SB")] --> EX
    /ConsumerDetails[(Type = "SE") or (Type = "CWE")] --> EX
    Receiver_2 (Conditions not working; except 1st condition):
    /ConsumerDetails[not(starts-with(UserId,'91200024:'))] --> EX
    /ConsumerDetails[(string-length(Date)) != "14"] --> EX
    /ConsumerDetails[(Billing != "RC") or (Billing != "SB")] --> EX
    /ConsumerDetails[(Type != "SE") or (Type != "CWE")] --> EX
    Only Conditions for Receiver_1 are working fine; those for Receiver_2 are not. Can anybody please provide correct conditions to be written in the Condition Editor?
    ~Thanks.

    Hello,
    Have you tried using the condition as mentioned below:
    /ConsumerDetails[not((string-length(Date)) = "14")] --> EX
    /ConsumerDetails[not((Billing = "RC")) or not( (Billing = "SB"))] --> EX
    /ConsumerDetails[not((Type = "SE")) or not((Type = "CWE"))] --> EX
    i.e. use not() instead of '!' ??
    -Rahul

  • XPATH in receiver determination

    Hi,
    We need to dynamically determine the receiver service based on the payload.
    In the extended service editor we have succesfully used a simple XPATH expression to point out a specific field of the payload (just like using af context object) containing the service name.
    However, in most cases the service name is a substring of a field of the payload and furthermore a constant is to be added to give the full service name. We have tried to solve this problem using the XPATH functions 'concat', 'string' and 'substring'. But as soon as we add just the simplest function to the XPATH expression, the receiver determination fails (unable to process the XPATH).
    We have tested the XPATH with the actual message using XML Spy, and it works well.
    The XPATH expression is: "concat('SAPR3_', substring(string(/p1:receipt/p1:identity), 2, 5))"
    Any hints?
    Regards
    Lars

    Hi Lars,
    I just noticed, that you are talking about extended Service Editor - not a Condition - so my answer above is obviously rubbish.
    What remains true is that the XPath you use has to result in a node, than the nodes string is taken as a service.
    So I am afraid there is no easy solution for your problem...
    If you do not have too many receivers and this list is rather static, you could of course use conditions in the receiver determination - something like:
    receiver service = SAPR3_b if /.../ = abc
    but this is of course not really applicable if the list of possible receivers gets too long.
    Another possibility would be to use the substring as a receiver within the configuration. So take it from the payload in the receiver determination and use this 'service' for interface determination and receiver agreement.
    Than, within the receiver agreement you can exchange this name by the 'real' name in the header mapping (which is performed as the very last step in the pipeline). Since you have a receiver agreement per receiver anyway, you would not have to create additional configuration objects. The downfall is of course, that to 'read' the configuration (or the message monitoring) one has to know about this mapping trick...

  • Purpose of Enhanced Receiver Determination

    Hi
       i go thrown  the some sap help link  .. But I did't understand.. so, can  any of you plz explain the what is the purpose of the  Enhanced Receiver determination..
    for this.. in mapping side does we need to do any special  things.. or for a normal  scenario also.. can we use this..
    I want to use this   Enhanced  Recever determination in  my scenario.. for that what are the steps  i need to  follow..
    Regards
    Babu

    Hi !
    Enhanced Receiver Determination:
    You use an enhanced receiver determination to have a mapping program determine the receivers of the message dynamically at runtime. Instead of creating the receivers in the receiver determination manually, you assign a mapping to the receiver determination and this returns a list of receivers at runtime.
    http://help.sap.com/saphelp_nw04/helpdata/en/43/a5f2066340332de10000000a11466f/content.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/42/ed364cf8593eebe10000000a1553f7/frameset.htm
    /people/venkataramanan.parameswaran/blog/2006/03/17/illustration-of-enhanced-receiver-determination--sp16
    also check this
    Please Check
    /people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible
    /people/venkataramanan.parameswaran/blog/2006/03/17/illustration-of-enhanced-receiver-determination--sp16
    http://help.sap.com/saphelp_nw2004s/helpdata/en/43/a5f2066340332de10000000a11466f/frameset.htm
    /people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination
    http://help.sap.com/saphelp_nw04/helpdata/en/42/ed364cf8593eebe10000000a1553f7/frameset.htm
    /people/venkataramanan.parameswaran/blog/2006/03/17/illustration-of-enhanced-receiver-determination--sp16
    Also check ....
    http://help.sap.com/saphelp_nw2004s/helpdata/en/43/a5f2066340332de10000000a11466f/frameset.htm
    http://help.sap.com/saphelp_nw04/helpdata/en/42/ed364cf8593eebe10000000a1553f7/frameset.htm -
    >Enhanced Interface determination.
    /people/shabarish.vijayakumar/blog/2006/06/07/customise-your-xpath-expressions-in-receiver-determination --->Customised XPath
    Also check the following threads
    Enhanced Receiver Determination
    Enhanced Receiver Determination synchronous
    /people/robin.schroeder/blog/2006/11/15/using-dynamic-receiver-determination-with-sync-interface
    /people/venkataramanan.parameswaran/blog/2006/03/17/illustration-of-enhanced-receiver-determination--sp16
    List of receivers can be dyamically determined and assigned at runtime using enhanced receiver determination .
    have alook at thses URl's also
    http://help.sap.com/saphelp_nw04/helpdata/en/43/01322a7af25285e10000000a1553f7/frameset.htm
    :Dynamic file and variable substitution
    Similarly Extended Receiver determination is used to determine the receiver at runtime.
    Refer my reply:Re: Condition In Receiver Determination Not Working
    enhancement in ID
    Enhanced Receiver Determination:
    You use an enhanced receiver determination to have a mapping program determine the receivers of the message dynamically at runtime. Instead of creating the receivers in the receiver determination manually, you assign a mapping to the receiver determination and this returns a list of receivers at runtime.
    http://help.sap.com/saphelp_nw04/helpdata/en/43/a5f2066340332de10000000a11466f/content.htm
    Enhanced (Mapping-Based) Interface Determination
    In an enhanced interface determination you do not enter the inbound interfaces manually, but instead first select a multi-mapping. You get the inbound interfaces from the target interfaces of the multi-mapping. The inbound interfaces are determined at runtime during the mapping step.
    You typically use an enhanced interface determination if the source message has an element with occurrence 0 ... unbounded (for multiple items of a data record) and you want multiple messages (for the individual items) to be generated at runtime.
    http://help.sap.com/saphelp_nw04/helpdata/en/42/ed364cf8593eebe10000000a1553f7/frameset.htm
    Thanks

  • Receiver Determination -- Expression Editor is empty

    Hi all,
    Scenario is the following:
    SAP (RFC) sends data to XI (3.0), XI sends it to Oracle DB (stored procedure)and gets back the return-message from Oracle, then forwards it to SAP (RFC). (Inbound Synchronous). Everything works well.
    Now I'd like to add just a condition to the existing  Receiver Determination and here's my problem:
    Receiver Determination --> Conditions --> Left Operand --> Expression Editor (there's no structure, everything empty!) I've even refreshed xi cache etc. No success!
    Could you please help me? All kind of suggestions / documentation are welcome!
    Thank you in advance!
    Greetings from NC
    Khaled

    Hi all,
    Thank you very much for your suggestions. FYI, I've done the followings:
    - Did clear SLD cache and 'Complete Cache Refresh' (TA:sxi_cache).
    - Did insert manually an xPath expression --> getting errors.
    - Did add the SWCV of Sender to the Receiver and vice versa (in SLD) --> so there's a link between both.
    Still not working and getting the message in Integration Builder: "Message interface no longer exists in the Integration Repository."
    I'll appreciate any further suggestions.
    Have a good time!
    Regards
    Khaled

  • XPath Expression at Condition Editor in Receiver Determination

    Hi,
      I have a fixed length flat file coming in into which I have to look at the first line's 4th to 7th positions. Based on that if it is "1234" then I need to route it to the receiver else I will ignore in the receiver determination.
    Example input file -
    M 0123456789ABCDEFGHIJKL
    PR0123456789JIDFJDIFJD0244
    PA0123456789JFDJF9384384K
    We have module configuration where we are converting this to a line value pair something like this -
    <?xml version="1.0" encoding="utf-8"?>
    <ns:GMTLog xmlns:ns="http://sap.com/xi/GMStoreConnectivity">
        <Line>
            <Value>M 0123456789ABCDEFGHIJKL
            </Value>
         </Line>
          <Line>
            <Value>PR0123456789JIDFJDIFJD0244
            </Value>
          </Line>
           <Line>
            <Value>PA0123456789JFDJF9384384K
            </Value>
          </Line>
    </ns:GMTLog>
    When I tried to test my xpath in xpath tester it is working fine with the below xpath expressions -
    1. /ns:GMTLog/Line[Value][1] --> This returned the first record completely
    2. substring(/ns:GMTLog/Line[Value][1], 4, 4) --> This returned exactly what I am expecting "1234"
    But the above 2 are not working in condition editor.
    May I know the exact xpath expression to be used in this case to route the message to receiver when 4th to 7th position is "1234".
    Thanks a lot in advance.
    Regards,
    Sarat

    Good day. Can I please have some clarity on what I need to correct on my Receiver expression test.
    For the number of instances of the Summary segment, I am required to identify and test the Summary amount of SUMME if this is more than 5.00 (a currency amount). SUMME is a string so I thought I should convert this to a "number" value to test it.
    Also ensuring that SUMME is checked when the SUMID is equal to 011.
    Now I hope part of my solution below is correct, but the test of the field value is not being done.
    Please help.

Maybe you are looking for

  • I accidentally formatted my portable hard drive when setting it up for time machine. Is there any way for me to get back my lost files?

    I have an external hard drive of the brand Western Digital. Before I got my iMac I moved a lot of my important files from my PC to the hard drive and today I went on and connected it to my iMac to move my files over to it. When it had connected a win

  • Posting a webpage right in an e-mail

    Hi, My friend who uses a PC always sends me e-mails with the webpage inbeded in the e-mail. Is it possible to do this on a Mac and if so how can I do it? I don't mean a link, I mean I open the e-mail up and the webpage is right there so I can click o

  • Premiere Pro CC 2014 MTS/AVCHD problems

    Hi All Ever since i updated my software last month I am having problems loading my footage from my camera (Sony A77). The camera produces the MTS files in an AVCHD format, which hassen't been a problem before. But now I just get an error:      - Erro

  • Raw and vista  loading problem

    I have loaded the trial version of cs 2 on my laaptop with vista ultimate, downloded all the latest updates for cs2, bridge, and raw place the raw plugin in the program/commonfiles/adobe/plugins/cs2/fileformats and sti;ll I cannot see any raw images

  • OVS in WDA  is not Advisable by SAP ?

    Hi All, Can anyone clarify me that OVS is not Advisable in WDA Applications  by SAP  is that True? In that case what is the alternative for Search  Help? Or Still we can Use OVS in WDA applications.. Thanks, Raju.