Fork me on GitHub
#clara
<
2017-01-16
>
wparker15:01:36

@skuro You’re correct that facts won’t be re-evaluated in this case. My suggestion would be to write something like

wparker15:01:42

(defrule ignore-old-facts [TimeFact (= ?time time)] [?fact <- Fact (too-old timestamp ?time)] => (retract! ?fact))

wparker15:01:14

If you retract an old TimeFact and then insert with a newer TimeFact this will force re-evaluation of the join

wparker15:01:13

There’s been some discussion on the mailing list of providing support for this sort of use case (events that expire with reference to them in Clara removed) but at this time there isn’t anything in Clara to directly support it.

skuro16:01:58

ok, thanks

wparker17:01:12

you’re welcome