Hello,
I would like to test the equality of a variable an a number into a <if>
activity but it does'nt work ...
I have a variable $precision :
<variable name="precision" type="xsd:string"/>
and I would like to test if this variable equals the number 2 :
<if name="coherencePrecisionChamp">
<condition>$precision=2</condition>
<then>
<assign name="assignError">
<copy>
<from>
<literal>Erreur</literal>
</from>
<to>$errorMsg</to>
</copy>
</assign>
</then>
<else>
<assign name="assignZut">
<copy>
<from>
<literal>Zut</literal>
</from>
<to>$errorMsg</to>
</copy>
</assign>
</else>
</if>
I send a message with precision equals 2 but I have always "zut" as result.
I have also tried the following conditions :
<condition>$precision='2'</condition>
<condition>number($precision)=2</condition>
<condition>number($precision)=number(2)</condition>
<condition>number($precision)=number('2')</condition>
but same result : "zut"
I have also tried to declare precision as a xsd:int but always the same.
The only way which works is :
<condition>contains($precision,'2')</condition>
but the condition is true for 12, 21, ... !!!
What is wrong in my syntax ?
Thanks,
Anne.
--
View this message in context:
http://www.nabble.com/BPEL---Boolean-equality-expression-tf3179916.html#a8823803
Sent from the Apache Ode User mailing list archive at Nabble.com.