[rules-dev] org.drools.rule.InvalidRulePackage: [0,-1]

Edson Tirelli tirelli at post.com
Mon Feb 23 08:23:35 EST 2009


   Lower case: 'end'.

   It seems this is a Drools 4 parser error message. In Drools 5 we have
much better error messages and they are documented.

   []s
   Edson

2009/2/23 Zevenbergen, Alex <azevenbergen at paddypower.com>

>  Hi all,
>
>
>
> I'm just starting to use drools, I am using it to house the rules regarding
> settlement of sports markets and such my rule packages should be relatively
> simple and straight forward (ie when match winner = x then settle x as
> winner)
>
>
>
> However my first attempt to create a drl is failing with the following
> error
>
>
>
> org.drools.rule.InvalidRulePackage: [0,-1]: unknown:0:-1 mismatched token:
> [@-1,0:0='<no text>',<-1>,0:-1]; expecting type END
>
>
>
> and I cant find much documentation online to help solve it.
>
>
>
> The complete drl file is:
>
>
>
> package xxx..rules.tennis
>
> import xxx.object.Fact
> import java.util.HashMap
> import function xxx.Settle_Selection.settle_selection
>
>
> rule "Player 1 wins match"
>         salience 100
>         agenda-group "tennis"
>         when
>                 $f : Fact()
>                 eval(($f.details["END_MATCH"].toUpper().toString().equal("TRUE")))
>         then
>                 settle_selection("test",20001","W");
> END
>
>
>
>
>
>
>
> Thanks in advance,
>
> Alex
>
>
>
> ________________________________________________________________________
> Privileged, confidential and/or copyright information may be contained in
> this communication. This e-mail and any files transmitted with it are
> confidential and intended solely for the use of the individual or entity to
> whom they are addressed. If you are not the intended addressee, you may not
> copy, forward, disclose or otherwise use this e-mail or any part of it in
> any way whatsoever. To do so is prohibited and may be unlawful. If you have
> received this email in error
> please notify the sender immediately.
>
> Paddy Power PLC may monitor the content of e-mail sent and received for the
> purpose of ensuring compliance with its policies and procedures.
>
> Paddy Power plc, Airton House, Airton Road, Tallaght, Dublin 24 Registered
> in Ireland: 16956
> ________________________________________________________________________
>
> _______________________________________________
> rules-dev mailing list
> rules-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-dev
>
>


-- 
 Edson Tirelli
 JBoss Drools Core Development
 JBoss, a division of Red Hat @ www.jboss.com
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-dev/attachments/20090223/851a11f6/attachment.html 


More information about the rules-dev mailing list