Jump to content
Changes to the Jaspersoft community edition download ×

variable is not calculated correctly


Recommended Posts

Hello everyone, I want to create a variable that counts every group in a report. I have the following variable declaration:


<variable name="busRouteNumber" class="java.lang.Integer" resetType="Group" incrementType="Group"
incrementGroup="busRouteGroup" resetGroup="busRouteGroup">
<variableExpression>new Integer($V{busRouteNumber}.intValue() + 1)</variableExpression>
<initialValueExpression>new Integer(0)</initialValueExpression>


It seems that the variable is not being calculated for every change in the group, but rather for every record in the report :S. Could anyone tell me what I'm doing wrong?


Thanx in advance

Link to comment
Share on other sites

  • Replies 1
  • Created
  • Last Reply

Top Posters In This Topic

Popular Days

Top Posters In This Topic

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Create New...