java - spliting rows in crosstab jasper-report -


i'm working jasper-report, have report want generate

my report

i have created class in java, in have field natureintervention displayed on columns, atelier on rows , numero used count in crosstab

public class champetatmaintenanceparnatureintervention {      private string natureintervention;     private string atelier;      private string numero;   } 

what i'm trying display each row atelier, list of vehicule types (ex: lourds, legers,....)

when generating crosstab row , column groups on every record need information.

in report see

  • 2 row groups (atelier , vehicule type)
  • 1 column group (motor type)
  • value of crosstab column

this suggest following getters on java object (that pass datasource)

public class mydatasourceclass {         public string getatelier(){.. return ...};     public string getvehiculetype(){.. return ...};     public string getmotortype(){.. return ...};     public string getvalue(){.. return ...}; //this maybe class } 

and cross tab groups be

<rowgroup name="atelier" width="150">     <bucket class="java.lang.string">         <bucketexpression><![cdata[$f{atelier}]]></bucketexpression>     </bucket>     ... header value.... </rowgroup>  <rowgroup name="vehiculetype" width="150">     <bucket class="java.lang.string">         <bucketexpression><![cdata[$f{vehiculetype}]]></bucketexpression>     </bucket>     ... header value.... </rowgroup>  <columngroup name="motortype" width="150">     <bucket class="java.lang.string">         <bucketexpression><![cdata[$f{motortype}]]></bucketexpression>     </bucket>     ... header value.... </columngroup> 

Comments

Popular posts from this blog

php - Wordpress website dashboard page or post editor content is not showing but front end data is showing properly -

javascript - Get parameter of GET request -

javascript - Twitter Bootstrap - how to add some more margin between tooltip popup and element -