Missing data (JasperReports Server reports)

2019-03-03 08:40发布

问题:

Ok so when I run my report in iReport I only get one row as output

100 100 -   BA  -   7294    -   1   -   3

But when I copy the query created by the report out of the server logs and run it I get 80 rows as output

100 100 -   BA  -   7294    -   1   -   3
100 101 -   BA  -   7294    -   1   -   3
100 102 -   BA  -   7294    -   1   -   3
100 103 -   BA  -   7294    -   1   -   3
100 104 -   BA  -   7294    -   1   -   3
100 106 -   BA  -   7294    -   1   -   3
100 107 -   BA  -   7294    -   1   -   3
100 108 -   BA  -   7294    -   1   -   3
100 109 -   BA  -   7294    -   1   -   3
100 110 -   BA  -   7294    -   1   -   3
etc...

I have done these kinds of reports a hundred times and this has never happened and I can't seem to find a solution

What can be the cause of this missing data ?

Here is the query I copied from the logs (Its a simple query, nothing fancy)

select 
`quallev_qualificationlevel`.`quallev_fieldofstudy` as 
`quallev_qualificationlevel_quallev_fieldofstudy`,
`qde_qualificationdescription`.`qde_shortdescription` as `qde_qualificationdescription_qde_shortdescription`,
`qde_qualificationdescription`.`qde_namepurpose_cd_id` as `qde_qualificationdescription_qde_namepurpose_cd_id`,
`cn_campusname`.`cn_campusid` as `cn_campusname_cn_campusid`,
`qde_qualificationdescription`.`qde_langauge_id` as `qde_qualificationdescription_qde_langauge_id`,
`fv_factorvalue_ft`.`fv_1` as `fv_factorvalue_ft_fv_1`,
`fv_factorvalue_ft`.`fv_2` as `fv_factorvalue_ft_fv_2`,
`fv_factorvalue_ft`.`fv_3` as `fv_factorvalue_ft_fv_3`,
`fosfte_fieldofstudyftefactor`.`fosfte_factor_cd_id` as `fosfte_fieldofstudyftefactor_fosfte_factor_cd_id`,
`fv_factorvalue_ft`.`fv_4` as `fv_factorvalue_ft_fv_4`,
`fv_factorvalue_ft`.`fv_5` as `fv_factorvalue_ft_fv_5`,
`fv_factorvalue_ft`.`fv_6` as `fv_factorvalue_ft_fv_6`,
`fv_factorvalue_ft`.`fv_7` as `fv_factorvalue_ft_fv_7`,
`fv_factorvalue_ft`.`fv_8` as `fv_factorvalue_ft_fv_8`,
`fv_factorvalue_ft`.`fv_9` as `fv_factorvalue_ft_fv_9`,
`fos_fieldofstudy`.`fos_code` as `fos_fieldofstudy_fos_code`,
`fosfte_fieldofstudyftefactor`.`fosfte_ftefactorvalue` as `fosfte_fieldofstudyftefactor_fosfte_ftefactorvalue`,
`qual_qualification`.`qual_code` as `qual_qualification_qual_code`,
`oun_organisationunitname`.`oun_ou_id` as `oun_organisationunitname_oun_ou_id`,
`fos_fieldofstudy`.`fos_startdate` as `fos_fieldofstudy_fos_startdate`,
`qh_qualificationhemis`.`qh_weight` as `qh_qualificationhemis_qh_weight`
from `qo_qualificationorganisation`
inner join `quallev_qualificationlevel` on (`qo_qualificationorganisation`.`qo_quallev_id` = `quallev_qualificationlevel`.`quallev_id`)
inner join `org_organisation` on (`org_organisation`.`org_be_id` = `qo_qualificationorganisation`.`qo_org_be_id`)
inner join `oun_organisationunitname` on (`oun_organisationunitname`.`oun_ou_id` = `org_organisation`.`org_ou_id`)
inner join `cn_campusname` on (`org_organisation`.`org_campusid` = `cn_campusname`.`cn_campusid`)
inner join `fos_fieldofstudy` on (`quallev_qualificationlevel`.`quallev_fos_id` = `fos_fieldofstudy`.`fos_id`)
inner join `qual_qualification` on (`quallev_qualificationlevel`.`quallev_qual_id` =     `qual_qualification`.`qual_id`)
inner join `qh_qualificationhemis` on (`qh_qualificationhemis`.`qh_qual_id` = `qual_qualification`.`qual_id`)
inner join `fosfte_fieldofstudyftefactor` on (`fosfte_fieldofstudyftefactor`.`fosfte_fos_id` = `fos_fieldofstudy`.`fos_id`)
inner join `qde_qualificationdescription` on (`qde_qualificationdescription`.`qde_qual_id`     = `qual_qualification`.`qual_id`)
inner join `fv_factorvalue_ft` on (`fos_fieldofstudy`.`fos_id` = `fv_factorvalue_ft`.`fv_fos_id`)
where `qde_qualificationdescription`.`qde_langauge_id` = 3 
and `fos_fieldofstudy`.`fos_startdate` <= '2013-11-08' 
and `qde_qualificationdescription`.`qde_namepurpose_cd_id` = 7294 
and `cn_campusname`.`cn_campusid` = '1' 
and `oun_organisationunitname`.`oun_ou_id` = '11' 
and `fosfte_fieldofstudyftefactor`.`fosfte_factor_cd_id` = 7699
group by `quallev_qualificationlevel`.`quallev_fieldofstudy`

Note: I am using iReport 5.0.0 on Win7 Pro 64bit for JasperReports Server 5.0.1 on Tomcat 7

回答1:

Ok so I finally found the solution

The problem was jasperserver had a default row limit set of 200,000

I raised that limmit to 2,000,000 and BOOOM !!! it works now :)