[rules-users] BRMS - how to use variables on Action part?

Felipe Piccolini felipe.piccolini at bluesoft.cl
Mon Oct 8 10:56:03 EDT 2007


Michael,

    Thanks a lot for the reply. This is exactly what I needed and it  
works fine :). It is true that is not so intuitive, but I guess a simple
mention on the documentation will be enought. You are right about  
keeping simple the GUI editor.

Thanks again. :)

On 06-10-2007, at 22:00, Michael Neale wrote:

> On the RHS, if you put "=" it will allow you to type in that  
> calculation.
>
> I guess that is not as intuitive as it shoudl be (on the LHS it  
> makes you tell it what you want to do), I am open to considering  
> changing that so it is more obvious.
>
> Yes, you can only access setters this way (at the moment).  
> Everything is based around fields and facts, (not so much objects).  
> The balancing act is to not put too much power into the GUI (as if  
> you want more, that is what DRL is for).
>
> On 10/4/07, Felipe Piccolini <felipe.piccolini at bluesoft.cl> wrote:
> Ok, so to fit on the "not ignored emails" from the list Mark  
> posted, I changed the title. However I following in the list
> anyways beacuse Im resending this email in less than 3 days.
>
> Note: Im not desperate, nor this is for today. This just came out  
> today yesterday and well... its important to me, but I
> think I can get a work around for now.
>
> So here is the real on-topic question.
> -----------------
> Anyone knows how to use variables (from fields) setted on LHS, to  
> modify a field on the RHS using the GUI editor
> from BRMS?
>
> What I need is to write this rule on BRMS.
>
> rule "Set approvedMount for a women"
> 	 no-loop true
> 	when
> 	 	$p: Person($sex: sex == "F" , $income: incomeMount)
> 	then
> 		$p.setApprovedMount($income * 1.2);
> 		update ($p);
> end
>
> I know I can use formulas, but I only know how to set those on LHS,  
> I dont know how to put a formula on RHS (setter of the field to  
> modify).
>
> Thanks.
>
>
> Felipe Piccolini M.
> felipe.piccolini at bluesoft.cl
>
>
>
>
>
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users
>
>
> _______________________________________________
> rules-users mailing list
> rules-users at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/rules-users



Atentamente,
______________________
Felipe Piccolini Marfull
Jefe de Proyectos
Agustina 1141 Piso 8-B
Santiago

Fono    +(56 2) 68830837
E-mail felipe.piccolini at bluesoft.cl





-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/rules-users/attachments/20071008/1cca20cc/attachment.html 
-------------- next part --------------
A non-text attachment was scrubbed...
Name: pastedGraphic.tiff
Type: image/tiff
Size: 262986 bytes
Desc: not available
Url : http://lists.jboss.org/pipermail/rules-users/attachments/20071008/1cca20cc/attachment.tiff 


More information about the rules-users mailing list