According to the documentaiton, you might try<br>   al.add( &quot;1=verygood&quot; );<br>etc.<br><br>-W<br><br><br><div class="gmail_quote">On Thu, May 7, 2009 at 9:32 AM, sreenivas555 <span dir="ltr">&lt;<a href="mailto:yssr_555@yahoo.com">yssr_555@yahoo.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><br>
hi All,<br>
<br>
I am loading the dropdown values from a DB / Bean. I want to even control<br>
the values it is internally using.<br>
For Example:<br>
[&#39;3=Good&#39;,&#39;4=Very Good&#39;] . It will display &#39;Good&#39; for us but internally, it<br>
uses the value 3 and display &#39;Very Good&#39; for us but internally uses 4.<br>
<br>
Same way I want to use when it is loading from DB.<br>
<br>
Java method.<br>
   public List getDataFromDb(){<br>
           ArrayList al=new ArrayList();<br>
                   al.add(&quot;verygood&quot;);<br>
                   al.add(&quot;good&quot;);<br>
                   al.add(&quot;bad&quot;);<br>
           return al;<br>
   }<br>
<br>
Above method is not giving me any control over the ids internally refered.<br>
<br>
I tried the following But it is not working. Not sure whether the following<br>
is correct. It is just a guess.<br>
 public Map getDataFromDb(){<br>
         Map m=new HashMap();<br>
         m.put(1, &quot;very good&quot;);<br>
         m.put(3, &quot;good&quot;);<br>
         m.put(5, &quot;bad&quot;);<br>
         return m;<br>
   }<br>
<br>
Any help on this highly appreciable!!!!<br>
<font color="#888888"><br>
--<br>
View this message in context: <a href="http://www.nabble.com/Enumeration-in-BRMS-tp23421669p23421669.html" target="_blank">http://www.nabble.com/Enumeration-in-BRMS-tp23421669p23421669.html</a><br>
Sent from the drools - user mailing list archive at Nabble.com.<br>
<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" target="_blank">https://lists.jboss.org/mailman/listinfo/rules-users</a><br>
</font></blockquote></div><br>