<br>&nbsp;&nbsp; I guess you are using the wrong mvel version. Please double check the MVEL jar to make sure it is the correct for the drools version you have.<br>&nbsp;&nbsp; <br>&nbsp;&nbsp; []s<br>&nbsp;&nbsp; Edson<br><br><div><span class="gmail_quote">2008/2/6, <a href="mailto:nemesis29@free.fr">nemesis29@free.fr</a> &lt;<a href="mailto:nemesis29@free.fr">nemesis29@free.fr</a>&gt;:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
Hello All,<br><br>Well i&#39;m trying to create a rule witch need to get some infos in the RHS that<br>are available in variables declared in the LHS part of the rule.<br><br>To make it clear (as my english is not on top ;-) here is an exemple:<br>
<br>the rule file :<br><br><br>rule &quot;NODSLVIP&quot;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;dialect &quot;java&quot;<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;when<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$rt : RuleTargetContainer()<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$travellers : TravellerListType() from $rt.metaDossier.travellers<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$traveller : TravellerType() from $travellers.traveller<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$user : UserType() from $traveller.user<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;$personalInfo : PersonalInfoType(isVIP == true) from $user.personalInfo<br>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;then<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println(&quot;VIP&quot;);<br>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;System.out.println($user.getName());<br>end<br><br>When i use it in my code i have the following exception trhown :<br><br>org.mvel.CompileException: problem encountered at node [11] 5{172,191}: unable<br>
to resolve token: declr.identifier<br><br>If i remove the line printing the user name all goes well (ie : i have VIP in my<br>trace when user is vip ^^ ).<br><br>What am i missing here? I have seen in the documentation that using LHS variable<br>
is possible bu can&#39;t make it work for my case :-( .<br><br>Thant in advance for any help you can supply.<br><br>N Beucler.<br>_______________________________________________<br>rules-users mailing list<br><a href="mailto:rules-users@lists.jboss.org">rules-users@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/rules-users">https://lists.jboss.org/mailman/listinfo/rules-users</a><br></blockquote></div><br><br clear="all"><br>-- <br>&nbsp;&nbsp;Edson Tirelli<br>&nbsp;&nbsp;JBoss Drools Core Development<br>
&nbsp;&nbsp;Office: +55 11 3529-6000<br>&nbsp;&nbsp;Mobile: +55 11 9287-5646<br>&nbsp;&nbsp;JBoss, a division of Red Hat @ <a href="http://www.jboss.com">www.jboss.com</a>