Posts tagged operators
I was experimenting with xpath expression and found that the ‘and’ and ‘or’ works perfectly as the logical operators.
I’m perosnally so happy to see them working. In few cases it was too hard to configure the conditional routes with just OR/AND joint.
I’ve attached an example to demonstrate a simple usage of ‘and’-‘or’ logical operators. This is the condition that I’ve put in the example.
(normalize-space(/process_data/@Input_Value1)=’555′ or normalize-space(/process_data/@Input_Value1)=’666′) and (normalize-space(/process_data/@Input_Value2)=’777′)
I believe that this is going to make workflow design so much cleaner. Instead of nested conditional routes and 4-5 decision points or set value steps we would be able to do lot more things in few steps now.
I think this is an XPath Explorer feature so is not limited to just route conditions. All of the places where XPath expression is evaluated should be able use these.
Hope this helps to you too!!!
Original article at http://blog.pandyaparth.com/2009/07/introducing-lc-keywords-logical-operators-andor/.