Title: Multislot with single value
Hello,
I'm having a slight problem. I have this template:
(deftemplate grouped-facts
facts that have been grouped
(slot partitionname)
(slot partitionvalue)
(slot summationvalue)
(multislot factcollection))
Where factcollection is a collection of
Is there a way to call one rule from another., instead of recreating
non-similar conditions in another rule too?
Is it required for dynamic bean to have m_name as property and a
constructor?
Thanks
Bhaskar
To
Title: Multislot with single value
Multifields require the $?varname syntax on the LHS.
You
might try the following:
(defrule bondMVMaxPCOutstanding::calcifnc (declare (auto-focus
TRUE)) (rulesfired (rules bondMVMaxPCOutstanding)) ?b - (grouped-facts
(partitionname cusip)
I think that Bhaskar wrote:
Is there a way to call one rule from another.
Hi Bhaskar,
First, make sure that you're not trying to procedurally control the rules
from firing, otherwise you violate the Zen of Jess
http://herzberg.ca.sandia.gov/jess/zen.shtml.
You might want to try using the
I think that Chirang wrote:
I need to check any of the facts have a particular slot value in the
factcollection.
Hi Chirang,
Two things:
1) You need to add a $ to the LHS pattern when matching a multifield.
So, you have to write: (factcollection $?fc) Make sure that you drop the $
when using the
Hi everybody,
It is written in "The Jess Language" section that
the forall conditionalrule :
Jess (defrule
forall-example (not (and (a ?x) (not (b
?x =)
would be activated, if for every fact (a ?x), there
is a fact (b ?x). However, after I added the forall rule and the following
Title: RE: JESS: forall conditional element
Did you do a (reset) before (run)?
alan
-Original Message-
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED]] On Behalf Of Nicolas Fortin
Sent: Monday, August 16, 2004 12:16 PM
To: [EMAIL PROTECTED]
Subject: JESS: forall conditional
I think [EMAIL PROTECTED] wrote:
Is there a way to call one rule from another., instead of recreating
non-similar conditions in another rule too?
If you're worried about duplication on the right-hand-side of rules,
you can write a deffunction, and call it on the right-hand-side of
both
One of the more annoying bits of Jess's CLIPS legacy is that it starts
up with an empty working memory, but for many kinds of rules to work
properly, the (initial-fact) asserted by (reset) has to be there. We
saw someone else bothered by this problem on the list today.
I was just wondering: would
Title: RE: JESS: (reset) and (initial-fact)
Could you introduce a new constructor with a switch controlling this behavior? The existing constructor could maintain the old behavior and anyone wanting the new behavior could use it explicitly.
Alternatively, could you have a derived Rete (or
Title: RE: JESS: forall conditional element
Hi Alan,
Thanks for your prompt answer. That was the
mistake. Sorry to annoy you with my newbie question. Thanks again,
Nicolas
- Original Message -
From:
Alan
Moore
To: '[EMAIL PROTECTED]'
Sent: Monday, August 16, 2004
Well, I guess we could ask under what conditions would it be undesirable for
Rete objects to be created in a reset state. If we can't think of any
negative side-effects, then no harm done and the benefits are as Ernest
stated.
As I understand it from
12 matches
Mail list logo