I am looking to use drools decision tables for a project. I want to add a condition where I verify that the value of a passed in object is less than a specified number. I want the decision table to look something like:
If you look at the third condition where I am checking the max size of the loan, I am calling a function: $t.getStandardLimit($n).
Unfortunately, I am unable to call the function inside the value cells with that syntax (drools reads it as a string and returns a syntax error). Is there a way to do this?
UPDATE: The solution was to add $param in the condition check (loanAmount <= $param)
Have not actually tested it but I think it may work:
for the Max loan condition, change it to loanAmount <= $param
.
If loanAmount is of type integer or double etc, it should work without problem because, after subtituting $param, both loanAmount <= $t.getStandardLimit($n)
and loanAmount <= 1000000
is a valid expression.