Implementation Guide for Oracle Self-Service E-Billing > Using the Reporting Engine > Customizing the Reporting Engine >

Unlimited Paging


By default, the Reporting Engine retrieves 1000 rows from the data source. You can configure the number of rows the Reporting Engine retrieves (maxRows or fetchSize) in the report XML file.

The following sample code shoes how to configure the size in the sample report.xml file:

<transformer id="tr1" ...>

<paging fetchSize="2000"/>

</transformer>

To retrieve all the rows from the data source without impeding performance, you can use unlimited paging. Unlimited paging enables the Reporting Engine to get the result set in batches and allows users to page across multiple batches. A fetch is one batch.

Unlimited paging retrieves result set rows in multiple fetches on demand when the user requests them. The user pages through the result set like regular paging. If the requested page is not in the current fetch, then the Reporting Engine gets the next fetch from the data source. However, all the intricacies of checking whether the requested page is in the current fetch, if not getting next the fetch, are hidden from the user.

Fetch size is the number of result set rows in one fetch. You can configure fetch size and page size in report XML. The following sample XML demonstrates how you can enable unlimited paging and to define the fetch size.

<transformer id="tr1" pageSize="20" ...>

<paging unlimited="true" fetchSize="5000"/>

</transformer>

The Reporting Engine supports unlimited paging for SQL data source and object data source. If unlimited paging is enabled, then sorting and calculator are not supported because it is necessary to sort and apply calculator operations for all the result set across all the fetches rather than current fetch.

Unlimited Paging for SQL Data Source

For the SQL data source you define the query as usual. The Reporting Engine embeds this query with in select count(*) to get the size of the total result set.

Unlimited Paging for Object Data Source

For the object data source to get the result set in batches, the data source provides the Reporting Engine with a call back method which retrieves the data from start position to end position. For this purpose, the Reporting Engine expects an object which implements the call back interface in report context rather than result set object. That means, for regular paging, you put result set list or array of objects in the report context and for unlimited paging, you put an object which implements call back interface. This call back interface is called IReportObjectResultSet and has the following methods:

public Object getResultSet (ReportObjectSearchCriteria objectSearchCriteria);

public int getResultSetSize();

ReportObjectSearchCriteria object has the start position and end position of a fetch.

The object you put in the result set must implement getResultSet and getResultSetSize().

The getResultSet(ReportObjectSearchCriteria objectSearchCriteria) method returns result set rows from start position to end position defined in objectSearchCriteria.

The getResultSetSize() method returns size of the complete result set that data source returns. If you do not know the result set size, then you can return IReportObjectResultSet.unknownResultSetSize.

Implementation Guide for Oracle Self-Service E-Billing Copyright © 2014, Oracle and/or its affiliates. All rights reserved. Legal Notices.