In general, you have to qualify the rule such that it won't fire
again; for instance (to adopt your syntax)
if userLicense.version == "enterprise" && userLicense.price != 1000
=>
set userLicense.price = 1000
I think [EMAIL PROTECTED] wrote:
[Charset iso-8859-1 unsupported, filtering to ASCII...]
> Hi all,
>
> If I have a bean in the engine say userLicense, and a rule
>
> if userLicense.version == "enterprise"
> =>
> set userLicense.price = 1000
>
>
> The problem with this rule is that if an instance of userLicense is added to the
>engine, the rule keeps firing. This is because the LHS always qualifies for firing.(I
>think)
>
> Is there an elegant way of avoiding this, or there a basic flaw in this logic.
>
> Thanks
>
>
---------------------------------------------------------
Ernest Friedman-Hill
Distributed Systems Research Phone: (925) 294-2154
Sandia National Labs FAX: (925) 294-2234
Org. 8920, MS 9012 [EMAIL PROTECTED]
PO Box 969 http://herzberg.ca.sandia.gov
Livermore, CA 94550
---------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the
list (use your own address!) List problems? Notify [EMAIL PROTECTED]
---------------------------------------------------------------------