on 05-06-2010 8:08 PM
Hi,
I am trying to use Xpath in the receiver Determination step and I want to check a field which is at item level and comes multiple times(0-unbounded) greater than 500.I tried with different options per SDN blogs,Xpath functions,but still I couldn't able to get what i am trying.I want to process the message when "quantity" is greater than 500,else I want to ignore the message with no errors.
I gave like this /p1: /LIST/item[quantity>499] EX
item loop is 0-unbounded and I need to check for every quantity.I selected the check box multi line as well.
I played around different options,but still did not get what I am looking for.
please suggest in this regard ,how I need to give the expression.
Thank you,
Sri
I need to re open this as my expression works only,if I have one line item and itemquantity > 500,but I need to check at all the line itemsquantities.
if 1st line itemquantity 600
2ns line itemquantity 300
3rd line itemquantity 800,then I should ignore,but the give expression still processing the message.
if all are above 500 then need to process the message.
one or more itemquantities in any one of the line items <500 then I should ignore the message.
please suggest how can I handle this in Xpath.
thank you.
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi,
For validating that the item field is occuring more than 500 times you need to choose the
2.The exact XPath would be in your case *(/p1: /LIST/itemquantity[499]EX)*
This means if the 500 th occurance of the item exists then the condition satisfies that is always true for 500 and above occurance of the item.
Please revert if the suggestion proves to be helpful.
cheers,
Abhishek.
Edited by: Abhishek Paul on May 6, 2010 10:55 PM
Edited by: Abhishek Paul on May 6, 2010 11:02 PM
Edited by: Abhishek Paul on May 6, 2010 11:08 PM
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Thank you Ramkumar and Abhishek for replies.
I solved it myself.
I gave like this //LIST/[itemquantity>499] EX and it worked.double forward slash in the front.
Ramkumar,I think you got me wrong.I am not checking for 499th occurence,I need to check for every occurence of itemquantity,if it is greater than value 500 then need to process else ignore the message.
can you try like this
/p1: /LIST[itemquantity > 499 ] EX {/code}
Regards
Ramg
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
User | Count |
---|---|
98 | |
11 | |
11 | |
10 | |
10 | |
8 | |
6 | |
5 | |
4 | |
4 |
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.