[rules-users] Problems parsing rules with brackets

bret bret.calvey at tietoenator.com
Mon Jan 15 09:28:06 EST 2007


Hi,

We are having issues with Drools where we have rules with brackets in the
"when" part of the rule.

For example...

rule "brackets"
	when
		 not ((DoubleFact(name == "a_fact", value > 60) or 
                          StringFact(name == "another_fact", value !=
"EMPLOYED")) 
                         and DoubleFact(name == "yet_another", value < 10))
	then
		assert(new PolicyViolation("Badness", "Blah"));
end

(The NOT line originally does not have line breaks, all of the when clause
is on one line)

This will cause a parse error and it complains about the bracket after the
NOT and at the end of the line.

Why can't drools deal with this??
-- 
View this message in context: http://www.nabble.com/Problems-parsing-rules-with-brackets-tf3014886.html#a8372324
Sent from the drools - user mailing list archive at Nabble.com.




More information about the rules-users mailing list