<html><body bgcolor="#FFFFFF"><div>Thanks for the answer. Yes, it may be easier to achieve with simple date fact but we have thousands of rules and each and every one of them has this temporal requirement. I was thinking along the lines of SessionClock. I know there is a 'realtime' and 'pseudoclock' implementation of it. May be I can write my own implementation of SessionClock and set any arbitrary date passed by the user into the knowledge session config. Then the rules attributes (@date-effective and @date-expires) can take care of filtering out the ones not effective on the date that I am setting in SessionClock. Am I thinking in the wrong direction?<br><br>Regards,<div><br></div><div>Faisal Shafique</div></div><div><br>On Mar 17, 2011, at 12:34 AM, Wolfgang Laun <<a href="mailto:wolfgang.laun@gmail.com">wolfgang.laun@gmail.com</a>> wrote:<br><br></div><div></div><blockquote type="cite"><div>The desired effect might be easier to achieve with a fact EffectiveDate { Date date; } and a pattern specifying the limits. <br><br>The rule attributes (not metadata) are based on the system data, and you wouldn't want to mess with it just to use data-effective and date-expires.<br>
<br>-W<br><br><div class="gmail_quote">On 17 March 2011 00:33, Faisal Shafique <span dir="ltr"><<a href="mailto:just_faisal@yahoo.com"><a href="mailto:just_faisal@yahoo.com">just_faisal@yahoo.com</a></a>></span> wrote:<br><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hi,<br>
<br>
Can I use any arbitrary date for the drools execution so that correct rules are fired based on not current date but any arbitrary date? This is in the context of @date-effective and @date-expires metadata that can be specified as part of a rule. Drools expert documentation seems to imply that this metadata uses "current date" though I am not clear what current date (system date?) means.<br>
<br>
Thanks<br>
<br>
Faisal Shafique<br>
<br>
<br>
<br>
_______________________________________________<br>
rules-users mailing list<br>
<a href="mailto:rules-users@lists.jboss.org"><a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a></a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users" target="_blank"><a href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a></a><br>
</blockquote></div><br>
</div></blockquote><blockquote type="cite"><div><span>_______________________________________________</span><br><span>rules-users mailing list</span><br><span><a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a></span><br><span><a href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a></span><br></div></blockquote></body></html>