Jump to content
Changes to the Jaspersoft community edition download ×

Howto generate Sequence No and to reset group


Recommended Posts

By: Harish - harishhebbar

Howto generate Sequence No and to reset group

2004-01-15 04:03

i am facing problem reseting group sequence no.


i am generating sequence no , but i am not able

to reset by group .


<variable name="SerialNo" class="java.lang.Integer" resetType="Group" resetGroup="ProjectSubGroup" calculation="System">

<initialValueExpression><![CDATA[($V{SerialNo} != null)?(new Integer($V{SerialNo}.intValue() + 1)):(new Integer(1))]]></initialValueExpression>



once seq is increased to say 10 , and when group reset is done,

sequence no remains as 10 forever.


<group name="ProjectSubGroup">



whenever projecttype is changed sequence no should reset to 1 and should start incrementing as long as projecttype remains same.




By: Vinod Kumar Singh - vinodsingh

RE: Howto generate Sequence No and to reset g

2004-01-15 21:05

You can use inbuilt variable groupname_COUNT.


Where group name the name of group, in your case ProjectSubGroup.


It works just like REPORT_COUNT, but it reset to 1 when group changes.



By: Harish - harishhebbar

RE: Howto generate Sequence No and to reset group

2004-01-18 22:12

Thanks it works fine.

Link to comment
Share on other sites

  • Replies 0
  • 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...