RE: AW: JESS: How to match Pattern in Facts

2004-08-10 Thread Orchard, Bob
Notice the lack of a space before the '?' in: Program text: ( defrule show-adv-attributes?fact <- You failed the parse of the program because of this. It thinks your rule name is show-adv-attributes?fact. Bob Orchard National Research Council Canada Conseil national de recherches Canada I

Re: AW: JESS: How to match Pattern in Facts

2004-08-10 Thread ejfried
I think calvin pevee wrote: > > r.executeCommand("(defrule show-adv-attributes" + > //"?fact <- (adv-attributes (id ?id) ... > > Java throws me this exception:- > > Jess reported an error in routine Jesp.parseDefrule. > Message: Expected '=>' . > Program text: ( defrule show-adv-

Re: JESS: Dynamic Type

2004-08-10 Thread ejfried
I think Mehta, Chirag (IT) wrote: > > Is there any way of accomplishing this? > This isn't really a Jess question at all -- it's a Java question, or anarchitecture question about your query mechanism. The issue is whether, when you obtain a data item, you know what the type of that data item is

JESS: Dynamic Type

2004-08-10 Thread Mehta, Chirag (IT)
Hello, I am trying to dynamically create a template according to the metadata from a database query. while (iterparm.hasNext()) { parmdata = (Element) iterparm.next(); System.out.println("in"); while (itermeta.hasNext()) {

Re: AW: JESS: How to match Pattern in Facts

2004-08-10 Thread calvin pevee
Hi, Need help here. I do not know how to get the facts out when it is embeded in Java. I ran the code in Java:- r.executeCommand("(deftemplate adv-attributes" + "(slot id)" + "(multislot attribs))"); r.executeCommand("(defrule show-adv-attributes" + //"?fact