Re: [rules-users] New in Drools: Updating facts retrieved in queries

2011-04-29 Thread Manuel Ortiz
Hi Wolfgang: Thank you very much for the explanation. Now everyting works fine. Best regards, Manuel Ortiz. 2011/4/29 Wolfgang Laun > > 2011/4/29 Manuel Ortiz > >> >> import es.simcasva.alarmas.src.MDSVHechoAlarma; >> >> >> query "existe Alarma" (MDSVHechoAlarma referencia) >> $alarma

Re: [rules-users] New in Drools: Updating facts retrieved in queries

2011-04-29 Thread Wolfgang Laun
2011/4/29 Manuel Ortiz > > import es.simcasva.alarmas.src.MDSVHechoAlarma; > > > query "existe Alarma" (MDSVHechoAlarma referencia) > $alarma : MDSVHechoAlarma( iIdAlarma == referencia.iIdAlarma, > > > The reported errors are: > > Description Resource Path Location Type > BuildError: Not

Re: [rules-users] New in Drools: Updating facts retrieved in queries

2011-04-29 Thread Manuel Ortiz
Hi again Wolfgang: Thank you for your quick answer. getFactHandle is the method I needed. Concerning the second question, I'm using Drools 5.1.1 and yes, I imported AlarmFact. Below you can find the relevant lines of the drl file, in which the 'real name' of AlarmFact is MDSVHechoAlarma: #create

Re: [rules-users] New in Drools: Updating facts retrieved in queries

2011-04-29 Thread Wolfgang Laun
You can call FactHandle fh = kSession.getFactHandle( factObj ); query "alarmExists" (AlarmFact key) should work in 5.1.1 and 5.2. Did you import AlarmFact in the DRL? Otherwise, what message are you getting in which version? -W 2011/4/29 Manuel Ortiz > Hello everybody: > > I have two qu

[rules-users] New in Drools: Updating facts retrieved in queries

2011-04-29 Thread Manuel Ortiz
Hello everybody: I have two question related to queries: First one, the one in the subject, I have a query which retrieves facts which have to be modified and updated in working memory. I've seen that the StatefulKnowledgeSession.update() method has the fact handle as input. Is it possible to set