On Dec 10, 2006, at 11:45 PM, Robert Kildare wrote:
I have spent a couple of hours with the manual and Jess in Action, but
must be suffering from man-blindness or wrong-tree barking. Can someone
help me to get the factID of a fact from within JESS?

If you've got the Fact object bound to a variable ?f -- for example, as by

(bind ?f (assert (foo)))

or on a rule LHS

?f <- (foo)

Then to get the numeric ID, you can say

(bind ?id (?f getFactId))

---------------------------------------------------------
Ernest Friedman-Hill
Advanced Software Research          Phone: (925) 294-2154
Sandia National Labs                FAX:   (925) 294-2234
PO Box 969, MS 9012                 [EMAIL PROTECTED]
Livermore, CA 94550                 http://www.jessrules.com
--------------------------------------------------------------------
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