Skip to Content
0
Former Member
Jul 09, 2008 at 02:41 PM

Problem with subreports not displaying correctly

86 Views

We recently switched from using Crystal Reports in .NET to using a Java/JRC solution. This has worked well except for one report we have. When run, the report looks something like this:

Totals for department A

Totals for department B

Totals for department C

...

<page break>

Totals for department A

Details for department A

Totals for department B

Details for department B

...

The first part of the report, with totals for all departments, is generated in a subreport based on a stored procedure that was placed in the report header. The repeating Totals/Details for each department come from two different subreports, also based on stored procedures, each of which is in a group header in the report. There is a group name field defined which is based on the department field from the stored procedure used by the main report, and the totals and details subreports have a parameter field which looks something like Pm-PROC.DEPARTMENT.

We populate all of our reports by calling DatabaseController.setDataSource() for the main report and calling JRCHelperSample.passResultSet() for subreport, and this has worked fine for all of the other reports we've used so far.

Unfortunately when we run this report we get the intial Totals page, but then no Totals for the first department, and details only for the first department.

Do I need to do something differently for this type of report? Is it possible that we're using something that is not supported in JRC?