I'd like to use a rule of the following form:

(defrule rule557
    (logical
        (is-active (name "Some name"))
        (in-coverage (tid ?tid) (cid ?cid) (distance ?distance&:(> 2
(count-query-results in-coverage-nearer-query ?tid ?distance))))
        )
    =>
    (assert (tracking-actual (tid ?tid) (cid ?cid)))
    )

The idea here is to limit the number of 'tracking-actual' facts w.r.t.
to the number of 'in-coverage' facts. It doesn't work, since I still
get a 'tracking-actual' fact for every 'in-coverage' fact.

The following modification works slightly better, but then I loose the
logical support, which I really need:

(defrule rule558
    (logical
        (sensor-doctrine-active (name "Some name"))
        (in-coverage (tid ?tid) (cid ?cid) (distance ?distance))
        )
    (test (> 2 (count-query-results in-coverage-nearer-query ?tid ?distance)))
    =>
    (assert (tracking-actual (tid ?tid) (cid ?cid)))
    )

Any suggestions, ideas, anyone?

TIA -+- JWL -+-


--------------------------------------------------------------------
To unsubscribe, send the words 'unsubscribe jess-users [EMAIL PROTECTED]'
in the BODY of a message to [EMAIL PROTECTED], NOT to the list
(use your own address!) List problems? Notify [EMAIL PROTECTED]
--------------------------------------------------------------------

Reply via email to