Hi Laune,
Vehicles list contains the values name and qty and the values are
car,10
jeep,20
lorry,30
car,30
Below is my implementation for that scenario which i have asked.
rule "HelloWorld_13"
salience 65523
when
$p1:Policy()
$trandet:Vehicle(name in ("CAR")) from $p1.vehicleslist
then
System.out.println($trandet.getQty());
end
The result for the above rule is
30
10
but i need 10 alone which is at the top of that list.. is that possible.?
and when googling found that if we use salience along with 'from' its
possible..
Please share your thoughts on the above.
Thanks
Salt
--
View this message in context:
http://drools.46999.n3.nabble.com/Getting-Latest-Matching-Fact-tp4019345p...
Sent from the Drools: User forum mailing list archive at
Nabble.com.