Are you setting the status attribute in the RHS of a rule? Are you updating the facts after you modify them?<div><br></div><div>Best,<br clear="all"><br>XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX<br><br>Esteban Aliverti<br>- Developer @ <a href="http://www.plugtree.com" target="_blank">http://www.plugtree.com </a><br>

- Blog @ <a href="http://ilesteban.wordpress.com" target="_blank">http://ilesteban.wordpress.com</a><br>
<br><br><div class="gmail_quote">2010/11/9 Dennis Duggan <span dir="ltr">&lt;<a href="mailto:dennis@esptechnologies.com">dennis@esptechnologies.com</a>&gt;</span><br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">










<div lang="EN-US" link="blue" vlink="purple">

<div>

<p class="MsoNormal">I have 2 types of objects in my knowledge base that I am
trying to equate.  Equality is based on a number of different variables
contained in the objects.  Once I find equal objects I set a status member
in each to “Matched”, otherwise it will be “OneKnows”
or “TwoKnows”.</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">After I fire the rules I use queries that I call from Java
code to get the three different types of objects.</p>

<p class="MsoNormal" style="text-autospace:none"><b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:#960000">query</span></b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> </span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:green">&quot;OneFirmKnows&quot;</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> </span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"></span></p>



<p class="MsoNormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black">    oRecord : MyObject1(
status==</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:green">&quot;OneKnows&quot;</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> )</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"></span></p>



<p class="MsoNormal" style="text-autospace:none"><b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:#960000">end</span></b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> </span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"></span></p>



<p class="MsoNormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"> </span></p>

<p class="MsoNormal" style="text-autospace:none"><b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:#960000">query</span></b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> </span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:green">&quot;TwoKnows&quot;</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> </span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"></span></p>



<p class="MsoNormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black">    oRecord : MyObject2(
status==</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:green">&quot;TwoKnows&quot;</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> )</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"></span></p>



<p class="MsoNormal" style="text-autospace:none"><b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:#960000">end</span></b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> </span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"></span></p>



<p class="MsoNormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"> </span></p>

<p class="MsoNormal" style="text-autospace:none"><b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:#960000">query</span></b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> </span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:green">&quot;Matched&quot;</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> </span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"></span></p>



<p class="MsoNormal" style="text-autospace:none"><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black">    oRecord : MyObject1(
status==</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:green">&quot;Matched&quot;</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> )</span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"></span></p>



<p class="MsoNormal" style="text-autospace:none"><b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:#960000">end</span></b><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;;color:black"> </span><span style="font-size:10.0pt;font-family:&quot;Courier New&quot;"></span></p>



<p class="MsoNormal"> </p>

<p class="MsoNormal">Each query sends back all objects no matter what the status
is.  The objects have a getStatus( ) method.  What am I doing wrong?</p>

<p class="MsoNormal"> </p>

<p class="MsoNormal">Thanks!</p>

<p class="MsoNormal">Dennis</p>

</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></div>