Converting query-based components to business view-based

In order for a query-based report component created in JReport Designer, such as table, crosstab, chart, and banded object, to be able to perform analytic reporting actions on when you work with them in Page Report Studio, JReport needs to convert the component from query-based to business view-based.

This section describes how JReport performs the conversion work and what a report designer should pay attention to in order to increase the opportunity of success in the conversion.

When the conversion is required

The conversion is required when Page Report Studio end user is trying to perform an analytic reporting action such as drilling through data on a table, crosstab, chart, or banded object which is created based on a query.

There is a report tab level property available in the Report Inspector of JReport Designer: Automatic Cube Initialization. When the property is set to true, JReport will automatically convert the queries a report tab uses to business views when opening the report tab in Page Report Studio.

What makes the conversion successful

The success of the conversion lies in the following aspects:

Tip: The report designer can create a complete and full-function business view for the required query, in this way, all fields in the query are able to be converted since there are always corresponding view elements found in the complete business view. To create such a complete business view, create a group and a detail object for each DBField and formula, and create an aggregation for each summary.

How to convert

The following lists what types of fields in the query will be converted to what types of elements in the business view:

When Query Fields Are Used As View Elements
Group by field | crosstab group | chart X axis | chart Z axis Group
Crosstab aggregation Aggregation
Chart Y axis & summary based on fields and function Aggregation
Chart Y axis & a Number data type element Detail object
Others & there are corresponding detail objects in the business view Detail object
Others & there are not corresponding detail objects in the business view Group

What cannot be converted

The following list shows the cases in a query-based component that do not support conversion. The list supposes that all the involved query fields have their corresponding view elements in the business view based on the query: