Why not add EmployeeTypeSalary objects to Working Memory, then you only need one static rule:-<br><br><span style="font-family:courier new,monospace">when</span><br style="font-family:courier new,monospace"><span style="font-family:courier new,monospace">  EmployeeTypeSalary( $et : emplyeeType, $s : salary )</span><br style="font-family:courier new,monospace">
<span style="font-family:courier new,monospace">  $e : Employee( employeeType ==  $et )</span><br style="font-family:courier new,monospace"><span style="font-family:courier new,monospace">then</span><br style="font-family:courier new,monospace">
<span style="font-family:courier new,monospace">  modify($e) {</span><br style="font-family:courier new,monospace"><span style="font-family:courier new,monospace">    setSalary( $s );</span><br style="font-family:courier new,monospace">
<span style="font-family:courier new,monospace">  }</span><br style="font-family:courier new,monospace"><span style="font-family:courier new,monospace">end</span><br style="font-family:courier new,monospace"><br style="font-family:courier new,monospace">
EmployeeTypeSalary represents individual rows in your database.<br><br>With kind regards,<br><br>Mike<br><br><div class="gmail_quote">On 23 August 2012 12:57, debchamps <span dir="ltr">&lt;<a href="mailto:majumdar.debarghya@gmail.com" target="_blank">majumdar.debarghya@gmail.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Hi<br>
I have the following requirement<br>
<br>
The rule is like if(employeeType == $1) set salary = $1<br>
<br>
emloyeeType                              salary<br>
---------------                             ---------------<br>
MANAGER                                          100<br>
SR Manager                                        200<br>
Director                                              300<br>
<br>
Now new employeeType  gets added every day. So the requirement is to  update<br>
the knowledgebase without again activating the service.<br>
<br>
So how to achieve that with Drools. I am using Drools with a Decision table<br>
for a different requirement in the same project. So if it can be achieved<br>
with decision table it would be great(So new rows will get added to the<br>
decision table dynamically but no column in this case).<br>
<br>
<br>
<br>
<br>
--<br>
View this message in context: <a href="http://drools.46999.n3.nabble.com/Drools-with-rules-from-database-tp4019357.html" target="_blank">http://drools.46999.n3.nabble.com/Drools-with-rules-from-database-tp4019357.html</a><br>

Sent from the Drools: User forum mailing list archive at Nabble.com.<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>
</blockquote></div><br>