Grouping, much like in an RDBMS, is a mechanism used to group data that falls into a similar category. This can be done with a SQL SELECT
statement using the GROUP BY
clause or, in BIRT, it can be done by adding a group to a Table or List. We are going to add to expand the above report examples by adding groups.
tblEmployeePayments
. Groups
tab and click on the Add button.grpEmployeePayments
dsetXMLEmployee::lastName
Now, when we preview the report, we can see that it adds an extra header with last names and groups all the like payments together. Of course, this will be better illustrated with the next example, where we modify the Order
table to display groupings by order number.
grpOrderInfo
ORDERNUMBER
tblEmployeePayments)
| Groups | Table Groups | Header | Row. Delete the row. Order Number
column. Under the General tab, click on the Suppress duplicates checkbox. Customer Number
column.Now, when we click on Preview, we can see that the orders are all grouped by the order number and, instead of repeatedly displaying the order number and customer number for each line like in the previous previews, it will now display it only once.