Hi Weily,

You need a space after the -



On 11/6/06, weily li <[EMAIL PROTECTED]> wrote:
Hi All,
 
Here is the exam DSL created:
 [when]the person =$person : Person()
 [when]-whose current danger is less than {level}=dangerLevel <={level}
 
 
 
Following is the DRL:
rule "sample_opeartor"
 when
  the person
   -whose current danger is less than 3 
 then
  ....
end
 
Here the field constraint '-whose current danger is less than 3' can't be expanded.
 
Exception:

org.drools.rule.InvalidRulePackage: unknown:56:0  Unable to expand: - whose current danger is less than 3. Due to _expression_ was not expandable: - whose current danger is less than 3

 at org.drools.rule.Package.checkValidity(Unknown Source)
 at org.drools.common.AbstractRuleBase.addPackage(Unknown Source)

...

Here is the corresponding DRL which works fine:
>  $person : Person(dangerLevel <=3) && Person(age >= (new Integer(service.getThrehold())));

 

Please help give helpful instruction to make it works.

Env:

Jboss IDE 2.0.0  with

Drools Plug-in:3.0.4

Thanks in adv!

rgds

Weily


 




 



--
Steven Williams

Supervising Consultant

Object Consulting
Office: 8615 4500 Mob: 0439 898 668 Fax: 8615 4501
[EMAIL PROTECTED]
www.objectconsulting.com.au

consulting | development | training | support
our experience makes the difference

Reply via email to