Hi!

I don't think it's a bug (at most a feature ;-)

With only Rule1 in place I would not expect the (not) CE to start backward
chaining, either. You can make it work by first issuing the following
statement, though:

     (expand (assert (fsm-select (need-Coord))))

That statement will make the Fact Storage Provider Framework preload all
Coord records.

Thomas




Hello jess users,

I use the Fact Storage Provider Framework to connect Jess with a database.

The database contains these tables:

Table "Data"
ID integer
PathToImage String

Table "Coord"
ID integer
UpperRightX
UpperRightY

where Data.ID and Coord.ID are the same.

(fsm-do-backward-chaining Coord)
(defrule Rule1
; try to find which images have NO entry in the Coord table
    (Data  (ID ?id) (Path ?path) (Media ?mediaID))
    (not (Coord (ID ?id)))
    =>
    (printout t "Pas de coordonnees pour l'image numero " ?id crlf))

Rule1 fires for all images (georefenced or not) in the Data table. It looks

like the backward chaining is not done when it is inside a (not).

This could be a design choice.  But things become inconsistant when Rule2
is
added.

(defrule Rule2
; try to find which images HAVE an entry in the Coord table
    (Data  (ID ?id) (Path ?path) (Media ?mediaID))
    (Coord (ID ?id))
    =>
    (printout t "Coordonnees existent pour l'image numero " ?id crlf))

If Rule2 is added, Rule1 fires for non-georeferenced images and Rule2 fires

for georeferenced images.

Is this a bug?

-Kami
_________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.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]
---------------------------------------------------------------------





+-------------------------------------------------------------+
| This message may contain confidential and/or privileged     |
| information.  If you are not the addressee or authorized to |
| receive this for the addressee, you must not use, copy,     |
| disclose or take any action based on this message or any    |
| information herein.  If you have received this message in   |
| error, please advise the sender immediately by reply e-mail |
| and delete this message.  Thank you for your cooperation.   |
+-------------------------------------------------------------+

---------------------------------------------------------------------
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