<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<HTML><HEAD>
<META http-equiv=Content-Type content="text/html; charset=iso-8859-1">
<META content="MSHTML 6.00.6000.16587" name=GENERATOR>
<STYLE></STYLE>
</HEAD>
<BODY>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Look at this....</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>I have got a "ContractWrapper" fact inserted into 
WM.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>It wraps a "Contract" object and some "enums" 
fields.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>One of these fields is "upronto":</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <DIV><FONT face=Arial size=2><B><FONT color=#7f0055 size=2>
  <P align=left>public</B></FONT><FONT size=2> </FONT><B><FONT color=#7f0055 
  size=2>class</B></FONT><FONT size=2> ContractWrapper </FONT><B><FONT 
  color=#7f0055 size=2>extends</B></FONT><FONT size=2> 
  BaseOmPersistentWithAssignedId{</P>
  <P align=left>Contract </FONT><FONT color=#0000c0 
  size=2>mycontract</FONT><FONT size=2>=</FONT><B><FONT color=#7f0055 
  size=2>null</B></FONT><FONT size=2>;</P>
  <P align=left></P>
  <P align=left>...</P>
  <P align=left></FONT><FONT size=2>Pronto </FONT><FONT color=#0000c0 
  size=2>upronto</FONT><FONT size=2> = </FONT><B><FONT color=#7f0055 
  size=2>null</B></FONT><FONT size=2>;</P>
  <P align=left><STRONG><FONT color=#7f0055>...</FONT></STRONG></FONT><FONT 
  size=2>
  <P align=left></P>
  <P align=left><EM>&lt;getters and setters....&gt;</EM></FONT><FONT 
  size=2></P></P></FONT><FONT size=2>
  <P align=left></P>
  <P align=left></P>
  <P align=left></P>
  <P align=left></P>
  <P>...</P>
  <P>}</P></FONT></FONT></DIV></BLOCKQUOTE>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>"upronto" is an insance of a "Pronto" java 
enum:</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<BLOCKQUOTE dir=ltr style="MARGIN-RIGHT: 0px">
  <DIV><B><FONT color=#7f0055 size=2>
  <P align=left>public</B></FONT><FONT size=2> </FONT><B><FONT color=#7f0055 
  size=2>enum</B></FONT><FONT size=2> Pronto {</P></FONT><I><FONT color=#0000c0 
  size=2>
  <P align=left>N</I></FONT><FONT size=2>,</P></FONT><I><FONT color=#0000c0 
  size=2>
  <P align=left>UNKNOWN</I></FONT><FONT size=2>,</P></FONT><I><FONT 
  color=#0000c0 size=2>
  <P align=left>Y</I></FONT><FONT size=2>;</P>
  <P align=left>}</P></FONT></DIV></BLOCKQUOTE>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>"Pronto" can be : (Y, N, UNKNOWN)</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Here is the rule which reasons over this 
enum:</FONT></DIV>
<DIV><FONT face=Arial size=2>(ofcourse I have got a Request into WM as 
well)</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><EM>rule "ScorePronto"<BR>dialect 
"mvel"<BR>ruleflow-group "Scoring"<BR>&nbsp;when<BR>&nbsp;&nbsp;&nbsp;&nbsp; 
$r:Request( $mc:mainContract != null )<BR>&nbsp;&nbsp;&nbsp;&nbsp; 
$cw_p:ContractWrapper($c_w_p:mycontract == $mc, eval(upronto != 
Pronto.Y))</EM></FONT></DIV>
<DIV><FONT face=Arial size=2><EM>&nbsp;then&nbsp;<BR>&nbsp;&nbsp;&nbsp;&nbsp; 
System.out.println("Test Result: "+($cw_p.upronto == 
Pronto.Y))&nbsp;&nbsp;<BR>end</EM></FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Any guesses for the output???</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Well....</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><STRONG>Test Result: true</STRONG></FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>HOW COMES???????????????????</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>I mean ... the test "eval(upronto != Pronto.Y)" 
returned "true".... It means that the rule</FONT></DIV>
<DIV><FONT face=Arial size=2>engine sees upronto &lt;&gt; Pronto.Y!, doesn't 
it??!!!!</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2><STRONG>So... why do I get "upronto == Pronto.Y" in 
the RHS????</STRONG></FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>What 
the.........&amp;$%%&amp;()%%$/%£....sorry....but having these</FONT></DIV>
<DIV><FONT face=Arial size=2>kind of problems during saturday night is not so 
pleaseant!&nbsp; </FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>T-T</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>I really hope you can help me&nbsp;with a 
&nbsp;workaround to this issue.</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Bye</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2>Massi</FONT></DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV>
<DIV><FONT face=Arial size=2></FONT>&nbsp;</DIV></BODY></HTML>