Record Limit

By default the DataSource will read all data records, up to the record limit specified in the WEB-INF\config\context\compatibility\afm-config.xml file:

<recordLimit output="html" ruleType="Message|Scheduled" perTgrp="100" perView="200"/>

The perTgrp record limit for output="html" sets the number of records exported in XLS file.

Setting any of these limits to “0” makes all records to be exported in file of the corresponding type.

You can override the default record limit on a case-by-case basis:

ds.setMaxRecords(500);
List records = ds.getRecords();

Note that larger data sets usually have a negative impact on performance and scalability. Because the effect depends on many factors -- such as application design, usage scenarios, and hardware/software configuration -- load tests are usually required to determine the acceptable record limits.

To retrieve all available records without applying a record limit, specify zero as a limit:

ds.setMaxRecords(0);

This is generally not recommended, because it might cause serious performance and load issues on the application server and on the database server. Access to tables that might contain hundreds of thousands of records should always be guarded using either a record limit, or a custom SQL query that filters and/or calculates relevant data. The latter technique can process very large data sets using SQL engines built into enterprise-grade database servers.

You can programmatically verify whether the data source could not retrieve all available records because of the record limit:

ds.setMaxRecords(500);
List records = ds.getRecords();
boolean hasMoreRecords = ds.hasMoreRecords();

The DataSource updates the hasMoreRecords property after each call to getRecords() method.

Note: There are four settings in the Global record limits section of the afm-config.xml file.

Setting Description
<recordLimit
output="html"
ruleType="Message"
perTgrp="100"
perView="200" />
Used by workflow rules and long-running jobs to limit records as described above.
<recordLimit
output="file"
ruleType="Message"
perTgrp="0"
perView="1000" />
Generates PDF files from 1.0 views
<recordLimit
output="none"
ruleType="Message"
perTgrp="0"
perView="0" />

Used internally by the core.

You should not use this setting.

<recordLimit
output="file"
ruleType="Scheduled"
perTgrp="0"
</recordLimits>

Has not been implemented.

You should not use this setting.

Record limits for reports generated by the XLS and DOCX action buttons

Record limits for reports generated from the grid control panel reporting (generated by XLS and DOCX action buttons for views that are not specialized panel reporting views) are determined by the following setting found in \WEB-INF\config\context\compatibility\afm-config.xml:

<recordLimit output="file" ruleType="Message" perTgrp="0" perView="1000"/>

The perView record limit for output="file" sets the number of records exported in DOCX file.

To override this global recordLimit, you can specify a per export recordLimit value when using the exportPanel command, such as:

<action id="abViewdefReport_export:XLS"> <title>XLS</title> <command type="exportPanel" outputType="xls" panelId="abViewdefReport_detailsPanel" recordLimit="1500"/> </action>

Record Limits for Paginated Reports

To increase record limits for paginated reports that are generated from a specialized reporting view (based on paginated reporting v iew – panel type=’paginatedReport’ ), change the following settings found in WEB-INF\config\context\reports\docx\reports-docx.xml :

  • recordsPerReportFile

  • drawingsPerFile

By default, the recordsPerReportFile is set to 2500 and drawingsPerFile is set to 500, but you can increase these limits if needed.

Record limits for reports generated from the grid control panel reporting (generated by XLS and DOCX action buttons for views that are not specialized panel reporting views) are determined by the following setting found in \WEB-INF\config\context\compatibility\afm-config.xml:

<recordLimit output="file" ruleType="Message" perTgrp="0" perView="1000" />

See Also

  • For information on setting the record limit in individual .axvw files, see the Record Limits section of the topic Define a Grid Report.

  • For information on narrowing the set of data records returned by the DataSource using one or more of object-oriented or SQL restrictions, see the topic Restrictions.