The properties of a dataset are:
| Property Name | Description | Editable | Formula Controllable | Data Type |
|---|---|---|---|---|
| General | ||||
| Class Type | Displays the class type of the object. | N | N | _ |
| Others | ||||
| Query Editor | Click on the right of the field to activate the Query Editor if the dataset is based on a query. |
Y | N | _ |
| Data Driver | Set cached query result file or report result file as the data resource. | Y | N | String |
| Maximum Records | Set maximum record number of the dataset you want to display. The default value -1 means that all the records of the dataset will be displayed. | Y | N | Integer |
| Query Name | Displays the query name. | N | N | String |
| Data Source Name | The name of the data source. | Y | N | String |
| Security | ||||
| Record Security | Click on the right of the field to set up a record-level security policy for the report. |
Y | N | _ |
| Function | Specifies a formula to control the record level security. | Y | N | String |
| Security Name | The name of the security imported from the catalog. | Y | N | String |
| Data Buffer | ||||
| Records per Page | Set the number of records in each page in the data buffer. | Y | N | Integer |
| Maximum Page Number | Set the maximum number of pages in the date buffer. | Y | N | Integer |
This property is usually for support purpose. When you have problems with your report, we need to run it and reproduce the problem so as to fix it. Sometimes, the database is too large to be sent. If this property is correctly set, then JReport engine will choose that query file to view the report instead of using JDBC driver or User Data Source to run the report.
To generate the cached query result, in the Catalog Browser, right-click the query of your report, click Create Cached Query Result, you can specify the folder and file name with or without extension (.txt).
The input format for cached query result is:
jrquery:/jet.universe.resultfile.UResultFileResultSet;Fullpath of cached query result.
The input format for report result file is:
jrquery:/jet.universe.resultfile.RResultFileResultSet;Fullpath of report result file.
You can improve the report performance by setting data buffer size. By default, the size of data buffer is 2M. When data exceeds the default size, they will be written on the disk, which will slow down the data processing. However, you may have enough memory which is much larger than the default buffer size, so that you can use the memory resource efficiently to achieve a better performance. JReport enables you to set the data buffer size by specifying the two properties of a dataset: Records per Page and Maximum Page Number.
When a buffer is defined, JReport divides it into many pages and allocates records to be stored in the pages. Data will be transferred with the unit of page. The data buffer size is determined by values of maximum number of pages in the buffer and the number of records in every page. The default maximum page number in the data buffer is 500, page size is 4k (page size = record size * Records per Page/1024, buffer size = page size * Maximum Page Number).
The value of Maximum Page Number should be changed with different reports. Generally speaking, it can be 1 ~ 50.
You can click Edit > Data Buffer Information... to view the data buffer information.
Notes: