[rules-users] objects

Chris Mathrusse christopher.mathrusse at sybase.com
Wed Jun 6 11:41:43 EDT 2007


I'm new to the rules syntax and a bit frustrated with trying to learn it. I've
reviewed the docs but keep running into the same issue. I have a parent object,
Message, that contains an Order. An Order has a status that I want to test. So
looking at the documentation and taking my best guess I've created a rule as
follows:
 
rule "Order not Accepted" 
when
  $m : Message( state == MessageState.RELEASING, order.requestStatus ==
RequestStatus.ACCEPT )
then 
  ...
end

The problem is that when I start my application I get a compilation error.

Caused by: 
org.drools.rule.InvalidRulePackage: [54,54]: unknown:54:54 mismatched token:
[@423,1899:1899='.',<69>,54:54]; expecting type RIGHT_PAREN[54,94]:
unknown:54:94 mismatched token: [@433,1939:1939=')',<37>,54:94]; expecting type
LEFT_PAREN
	at org.drools.rule.Package.checkValidity(Package.java:368)

 
So what am I missing? I know it has to be something simple with my understanding
of the syntax.
 
Thanks for the help...




More information about the rules-users mailing list