I have the Definitive Guide to iReports and I followed those instructions on counting the occurences of a group, but the counts are incorrect once the report is filled. Numbers show up, but they are counting something other than the counties.
Here's the situation. I created 2 Report Groups: State and County. I want to count the number of Counties for each State. I created a new Variable with Variable Class Type as java.lang.Integer and the Calculation type as Count.
My Variable Expression is as follows: ( $V{County_COUNT} != null && $V{County_COUNT}.intValue() == 1 ) ? "" : null
The Initial Value Expression is: new Integer(0)
The Eval. time is "Group" and the Eval. Group is "County".
Is there something that I'm overlooking or is there another way of solving this?
Counting Group Occurences
in Products
Posted
I have the Definitive Guide to iReports and I followed those instructions on counting the occurences of a group, but the counts are incorrect once the report is filled. Numbers show up, but they are counting something other than the counties.
Here's the situation. I created 2 Report Groups: State and County. I want to count the number of Counties for each State. I created a new Variable with Variable Class Type as java.lang.Integer and the Calculation type as Count.
My Variable Expression is as follows: ( $V{County_COUNT} != null && $V{County_COUNT}.intValue() == 1 ) ? "" : null
The Initial Value Expression is: new Integer(0)
The Eval. time is "Group" and the Eval. Group is "County".
Is there something that I'm overlooking or is there another way of solving this?