Report Wizard - Subreport Tab

JReport allows a report (referred to as the subreport) to be inserted into another report (referred to as the primary report).  There is no difference between the primary report and the subreport.  A subreport can be standalone, i.e. it can be run separately like a normal report or it can also include another subreport.

A link is the way of creating connections between the primary report and the subreport.

Sub Links:

A Sub Link is the relationship between the primary report and the subreport.  You can build up one or more links between a primary report and a subreport.  When you build a link, JReport will match up the records with equal relationships within the subreport and the primary report.  For example, let's say we have a primary report that is focused for customers and the subreport for orders.  When we build the link between them, JReport will build a subreport for each customer.  The subreport will only include those order records for that customer. 

How to create a subreport:

Go to the File menu and click New to create a new report.  Select the Subreport icon in the New tab, in the Choose Report window.  The following window should appear:

help132.gif (12785 bytes)

Complete all the necessary
information in the Data, Query, Display, Group/Sort, Summary, and Graph tabs.

The Subreport window consists of the following main items: