I don't believe it is possible to negate rules in Guvnor using the guided editor. Please raise a JIRA for an enhancement.<br><br>AFAIK the only work around would be to specify "Free form DRL" when constructing the pattern.<br>
<br>With kind regards,<br><br>Mike<br><br><div class="gmail_quote">On 29 April 2011 21:46, Dean Whisnant <span dir="ltr"><<a href="mailto:dean@basys.com">dean@basys.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin: 0pt 0pt 0pt 0.8ex; border-left: 1px solid rgb(204, 204, 204); padding-left: 1ex;">
<br>
Hi,<br>
<br>
I have a rule where I want to check if an object doesn't exist or it exists and a field in it is null or a field in it is D.<br>
<br>
Here's .drl code that works<br>
<br>
rule "test does not exist is null or is D"<br>
when<br>
(not CLM_DET_LOAD_PendCode() ||<br>
CLM_DET_LOAD_PendCode(pendCode_29== (null)) ||<br>
CLM_DET_LOAD_PendCode(pendCode_29== "D")<br>
)<br>
then<br>
System.out.println("CLM_DET_LOAD_PENDCOE does not exist, is null, or is D");<br>
End<br>
<br>
Normally in Guvnor to do an Or, I choose "Any of the following are true..." from the 'Add a condition to the rule...' dialogue. But when I choose this and then try to do the "not" logic, there is no choice for 'not'. I can get the other two conditions in just fine. Short of putting freeform DRL language in there, do you have any suggestions? Am I missing an option in guvnor?<br>
<br>
Thanks<br>
<br>
Dean<br>
<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</blockquote></div><br>