Thanks Olivier
Sowmya
-----Original Message-----
From: rules-users-bounces(a)lists.jboss.org [mailto:rules-users-bounces@lists.jboss.org] On
Behalf Of Olivier THIERRY
Sent: Tuesday, December 16, 2008 1:59 PM
To: Rules Users List
Subject: Re: [rules-users] DSL: Problem of having 2 DSL statements that endsdifferently
I had the same kind of problem : Drools stops on the first DSL sentence it can map to.
If you want it to work, you have to be careful about the order you write sentences in your
DSL : write them from the most restricitive to the less.
In your case it should be :
This is a "{node1}" in "{tree}"
This is a "{node1}"
Note Drools tools for Eclipse have nothing to change order, so you will have to open your
DSL file as a text file to do this ;)
Regards,
Olivier
2008/12/16 cmgoh <cmgoh1979(a)gmail.com>:
Hi,
Further working with DSL (btw, we are using Drools 4.0.7), I found out
that if there are two DSL statements such as:
This is a "{node1}"
This is a "{node1}" in "{tree}"
Drools will throw some errors:
Exception in thread "main" org.drools.rule.InvalidRulePackage: Rule
Compilation error : [Rule name=aC, agendaGroup=MAIN, salience=0,
no-loop=false]
org/doxa/rules/deployer/Rule_aC_0.java (25:1671) : in cannot be resolved
org/doxa/rules/deployer/Rule_aC_0.java (25:1674) : Syntax error
on token ""tree3"", invalid AssignmentOperator
at org.drools.rule.Package.checkValidity(Package.java:424)
at org.drools.common.AbstractRuleBase.addPackage(AbstractRuleBase.java:394)
at
org.doxa.rules.deployer.RuleRunnerWithDSL.runRules(RuleRunnerWithDSL.java:36)
at
org.doxa.rules.deployer.RuleRunnerWithDSL.main(RuleRunnerWithDSL.java:
118)
Is this a bug? It took me almost 1 day to discover this. Hope this
will provide other DSL users some light.
Best regards
Eric
--
View this message in context:
http://www.nabble.com/DSL%3A-Problem-of-having-2-DSL-statements-that-e
nds-differently-tp21028958p21028958.html
Sent from the drools - user mailing list archive at
Nabble.com.
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users
--
Seules 2 choses sont infinies : l'univers et la bêtise humaine ; et encore pour
l'univers, je ne suis pas sûr ... (Einstein)
_______________________________________________
rules-users mailing list
rules-users(a)lists.jboss.org
https://lists.jboss.org/mailman/listinfo/rules-users
This e-mail (and any attachments), is confidential and may be privileged. It may be read,
copied and used only
by intended recipients. Unauthorized access to this e-mail (or attachments) and disclosure
or copying of its
contents or any action taken in reliance on it is unlawful. Unintended recipients must
notify the sender immediately
by e-mail/phone & delete it from their system without making any copies or disclosing
it to a third person.