Re: JESS: Facts Containing Facts

2009-08-20 Thread Wolfgang Laun
Your rule (not a query) might go like this, if you are using unordered facts: (defrule checkAuthorization (Attempt person ?person)(action ?action)) (Authorization (person ?person)(action ?action)) => (assert (Action (action ?action))) ) Check the manual for the correct syntax for ordered f

Re: JESS: problems when using a clear

2009-08-20 Thread Jim Yates
Why not use a marker and then a reset. This will clear all facts asserted since the marker was set. On Thu, Aug 20, 2009 at 9:12 AM, Joao Carlos Mourao < joao.mou...@nl.thalesgroup.com> wrote: > The clear is used for running the system multiple times. For example, the > user starts the program,

Re: JESS: problems when using a clear

2009-08-20 Thread Joao Carlos Mourao
The clear is used for running the system multiple times. For example, the user starts the program, gets his results, and then wants to repeat the process (maybe with other input data). I want to ensure that everything from the last use gets clean. That's why i need a clear. In the current versio

JESS: Facts Containing Facts

2009-08-20 Thread kartik tadanki
Hi, I am trying to fire a query somewhat like this : (defrule checkAuthorization Attempt (?person, ?action) Authorization(?person, ?action) => (assert (?action)) ;// let the action happen ) Here ?m may be a fact like : Open(door) - or - Puchase (goods) Comments and suggestions welc

Re: JESS: problems when using a clear

2009-08-20 Thread Ernest Friedman-Hill
On Aug 20, 2009, at 4:24 AM, Joao Carlos Mourao wrote: Other important note is that when i don't use clear, and just start the system from scratch (batch - reset - and run-until-halt), the rule- based system works perfectly. The problem arises when i put a clear in the beginning of the chai

Re: JESS: JESS Simple Variable Question

2009-08-20 Thread John Chrysakis
OK thanks Ernest for your help! On Wed, 19 Aug 2009, Ernest Friedman-Hill wrote: > Yes, as I said, it would be > > (calling goToSlide "TEST" (+ ? slide 1)) > > On Aug 19, 2009, at 4:43 AM, John Chrysakis wrote: > > > > > Hi, > > > > I used: (calling goToSlide "TEST" + ? slide 1) > > > > but I

Re: JESS: problems when using a clear

2009-08-20 Thread Joao Carlos Mourao
Ernest Friedman-Hill wrote: "if the function "insert-rules-and-templates-using-batch" were a deffunction, it would be undefined" The insert-rules-and-templates-using-batch is a clp file containing templates, rules, queries, deffuctions (why not), everything that i need to have in my knowledge