Earlier in the user guide you learned about report sections. Next we will activate our report's sections. From the
menu, select the option. The following screen will appear:Select the following options using your mouse:
Report Header
Report Footer
Page Footer, Any Page(s)
Page Footer, Last Page
You'll see later that we will leave the contents of the Page Footer, Last Page blank, as this will suppress the printing of the Page Footer, Any Page(s) so that only the report footer will print at the end of the report and we will not have a redundant section. This technique also applies to report headers, but not in this case as this report will contain only a report header and a group header, which we are about to define:
From the Detail Sections display, select the unnamed detail section and click the button. Set the following:
Change to "group".
Select the one you just entered called
.Leave unchecked. We will only have one section and will chose not to set a page break.
Click the
button to add a new group.You will now see a Group Section Editor screen that you will fill in with the following values as shown below:
A group section enables you to identify a column in the query by which we will organize the display of the information. In this example we have call reports filed by several people. By grouping on the LastName
column, we will have a report that organizes calls by caller. The options available to us include the following:
Creates a group header section. Frequently used to display the column by which the report is grouped (in this case the caller's last name) and report column descriptions.
Creates a group footer section in which footer information, such as sub-total and total query results, may be displayed.
When selected, a page break is inserted between the end of one set of groups and the beginning of the next.
Upon clicking
on the Group Section Editor and then the Detail Section Properties screens, you will find that your Section Editor screen now has a Detail Section called "group", as shown below:Closing the Section Editor screen now returns you to the report's layout. This will now include space for all of the sections you have created, as shown below:
The example shown above has been populated with the following information defined by section:
The report's title and a line. This appears on the first page only.
This is the header for the group you just created called "contact". It will display the caller's first and last names from the query. Note that while the query may return many rows for a caller, the caller's first and last name will be displayed only from the first row for each group. It will also display the column headers above each set of calls grouped by caller.
This section displays the rows returned for each caller. In the group header we display the caller's name. Here we display the details for one or more calls made by this caller.
The contents of this section display at the end of each set of calls for each caller.
The context query called "page_number" is used here to display a page number on the bottom the last page of the report.
The next section is a Page Footer (Any) which will put a page number on every page, including the report footer—which would be redundant if we take no action. A blank Page Footer (Last) serves to override the Page Footer (Any) with a blank footer on the last page so that the only page number displayed on this page is the one from the report footer.
This places a page number on every page of the report. We suppress this on the last page of the report with a blank Page Footer (Last) so that only the report footer is used.
Next we will define the parameters that will be used at run time when the report is generated with the report renderer.