<html><head></head><body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; ">Hey Edson and Wolfgang,<div><br></div><div>I went to setup an example app and rules file to send you, and it seemed to work correctly. So now I have to figure out the difference between the sample code and application code. Hopefully, I'll be able to find it.</div><div><br></div><div><br></div><div>Thanks to both of you for your help.</div><div>Mike</div><div><br></div><div><br></div><div><br><div><div>On Jan 25, 2010, at 10:22 AM, Edson Tirelli wrote:</div><br class="Apple-interchange-newline"><blockquote type="cite"><br>&nbsp;&nbsp;&nbsp; Mike,<br><br>&nbsp;&nbsp;&nbsp; Wolfgang has it right. When you write:<br><br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; property : StatusProperty( name == "propertyName", value == "valueA" )<br><br>&nbsp;&nbsp;&nbsp; You are telling the engine that the StatusProperty is a fact in the working memory. Reading that, I assumed you were inserting them, because if they are not facts in the working memory, the rule will obviously never match.<br>
<br>&nbsp;&nbsp;&nbsp; If you don't want to insert them (although recommended), you need to rewrite the pattern using "from" to tell the engine where to look for the properties. Example:<br><br>when<br>
 &nbsp; &nbsp; &nbsp; &nbsp; &nbsp; &nbsp;t : TrainingStatus( currentSection == "section_a" )<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp;&nbsp; property : StatusProperty( name == "propertyName", value == "valueA" ) from t.properties<br>then<br>end<br><br>&nbsp;&nbsp;&nbsp; []s<br>
&nbsp;&nbsp;&nbsp; Edson<br><br><div class="gmail_quote">2010/1/25 Mike Dougherty <span dir="ltr">&lt;<a href="mailto:mjdougherty@gmail.com">mjdougherty@gmail.com</a>&gt;</span><br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<div style="word-wrap: break-word;">Hello Wolfgang,<div><br></div><div>Thank you for the response. However, as I read this documentation this should not be necessary. Even still, if I try it, it does not seem to help.</div>
<div><br></div><div><br></div><div>Thanks,</div><div>Mike</div><div><br></div><div><br></div><div><br><div><div><div></div><div class="h5"><div>On Jan 24, 2010, at 9:17 AM, Wolfgang Laun wrote:</div><br></div></div><blockquote type="cite">
<div><div></div><div class="h5">On Sun, Jan 24, 2010 at 8:16 AM, Mike Dougherty <span dir="ltr">&lt;<a href="mailto:mjdougherty@gmail.com" target="_blank">mjdougherty@gmail.com</a>&gt;</span> wrote:<br><div class="gmail_quote">
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>
I'm inserting a TrainingStatus object that should match this rule. But the resulting object does not have the nextSection and previousSection fields set to the values they should.</blockquote><div><br>Only because you mention the insertion of the TrainingStatus object but not the one(s) of (a) StatusProperty object(s): They should be inserted, too!<br>

<br>-W<br><br></div></div><br></div></div><div class="im">
_______________________________________________<br>rules-users mailing list<br><a href="mailto:rules-users@lists.jboss.org" target="_blank">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>
</div></blockquote></div><br></div></div><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>
<br></blockquote></div><br><br clear="all"><br>-- <br> &nbsp;Edson Tirelli<br> &nbsp;JBoss Drools Core Development<br> &nbsp;JBoss by Red Hat @ <a href="http://www.jboss.com/">www.jboss.com</a><br>
_______________________________________________<br>rules-users mailing list<br><a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>https://lists.jboss.org/mailman/listinfo/rules-users<br></blockquote></div><br></div></body></html>