[rules-users] Arithmetic operator in Condition part (Argent help.....)

Nikhil_dev k.nikhil at verchaska.com
Wed Feb 13 00:46:59 EST 2008


Hi!!!, vdelbart,
thank u for the solution, but is there any way i can run it with moving the
object 

there is 1 more for which i need a solution

the following Rule dosen't work

package com.vtech.fareengine.module.rulemanagermodule
import com.vtech.fareengine.module.rulemanagermodule.Bean.ApplyRuleBean;
rule  "Rule_decimal_1"
dialect "java"
when 
        $a : ApplyRuleBean()  
         m : ApplyRuleBean ( ($a.AdultFare - $a.InfantFare) < ($a.ChildFare
+ $a.InfantFare) )
then 
         $a.GrossFare = ($a.ChildFare * 500);
end
Follwing is the Error wat i get on compiling :
sourceDRL :: java.io.StringReader at 1daf835
[7,36]: unknown:7:36 Unexpected token '-'[7,69]: unknown:7:69 mismatched
token: [@74,264:264='+',<71>,7:69]; expecting type LEFT_PAREN[7,84]:
unknown:7:84 mismatched token: [@79,279:279=')',<12>,7:84]; expecting type
LEFT_PAREN[7,86]: unknown:7:86 mismatched token:
[@81,281:281=')',<12>,7:86]; expecting type THEN
java.lang.RuntimeException: Unable to compile drl

is there any solution for this.

-- 
View this message in context: http://www.nabble.com/Arithmetic-operator-in-Condition-part-%28Argent-help.....%29-tp15430904p15450027.html
Sent from the drools - user mailing list archive at Nabble.com.




More information about the rules-users mailing list