Yes, that is correct.
   Why do you mean by a "cleaner" way?

    []s
    Edson

2007/9/12, Christopher.Mathrusse@sybase.com <Christopher.Mathrusse@sybase.com>:

I'm using a DSL with my DRL file and I've read through the documentation but I've gotten hung-up on the syntax. Below is a rule from my DRL and the expansion in my DSL.

My rule in the DRL:
rule "Maximum Order Amount Exceeded"
salience 9800
        when
                   There is an Order with
                   - an amount that exceeds 100000        
        then
                Manually release the Order
               
end


My DSL:
[condition][]There is an Order with=Order()
[condition][]- an amount that exceeds {number}=amount >= {number}
[consequence][]Manually release the Order=setManualRelease(drools.getRule().getName());

What I would like to do is add to my consequence the following in red:
[consequence][]Manually release the Order=setManualRelease(drools.getRule().getName());retract(theOrder);


I know that I would need to modify my condition statement to be able to use the variable theOrder  in my call to retract:
[condition][]There is an Order with=theOrder : Order()


but is there a cleaner way to achieve this?

_______________________________________________
rules-users mailing list
rules-users@lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users




--
  Edson Tirelli
  Software Engineer - JBoss Rules Core Developer
  Office: +55 11 3529-6000
  Mobile: +55 11 9287-5646
  JBoss, a division of Red Hat @ www.jboss.com