Hi,
I am new to Drools. I am having a problem comparing 2 double
values. I have a Java class with a double attribute called loanToValue. The
loanToValue is been read from an XML file and the value is 92000.0. Based on
this value I do not expect this rule to be fired, but for some reason it does.
And the print statement returns 92000.0. Does anyone know what I’m doing
wrong? My rule looks as follows:
rule "G2 Equity
in Asset"
ruleflow-group "goods"
dialect "mvel"
when
$d
: IndividualDecision()
Individual(eval($d.getLoanToValue() < "85"))
then
System.out.println("loanToValue:
" + ($d.getLoanToValue()));
end
Thanks,
Ade
Adeyinka Timi | Technical Supprt | Nathean Technologies Ltd
Registered Office
T +353 1 685 3001
| VOIP 076 615 1117 | E
adeyinka.timi@nathean.com | www.nathean.com
Incorporated in
The information appearing in this email and
any files transmitted with it is confidential and may not be reproduced,
modified, distributed, transmitted, displayed, published or broadcast without
the prior written permission of Nathean Technologies Ltd. It is intended solely
for the use of the addressee(s). Nathean Technologies Ltd, its directors,
officers and employees do not accept liability for any loss or damage of any
nature howsoever arising pertaining to the use of information appearing in this
email and/or any files transmitted with it. Whilst this email has been checked
for the presence of computer viruses, Nathean Technologies Ltd does not, except
as required by law, represent, warrant and/or guarantee that the integrity of
this communication has been maintained nor that the communication is free of
errors, viruses, interception or interference.