Re: [rules-users] how to do things like "distinct"?

2011-06-01 Thread Wolfgang Laun
On 1 June 2011 16:55, Simon Chen wrote: > Hi all, > > I have the following problem. > > Let's say, I have a class Number3(), with three fields a, b, and c. > > I have the following rule: > > rule "test3" >when >Number3($a: a, $b: b) >$minvalue: Number() >from accum

[rules-users] how to do things like "distinct"?

2011-06-01 Thread Simon Chen
Hi all, I have the following problem. Let's say, I have a class Number3(), with three fields a, b, and c. I have the following rule: rule "test3" when Number3($a: a, $b: b) $minvalue: Number() from accumulate(Number3(a == $a, b == $b, $c: c), min($c)) then