Inserting a crosstab
To insert a crosstab into a report or a library component, use either of the following two ways:
- Using the wizard
- Position the mouse pointer at the destination where you want to insert the crosstab. A crosstab can be inserted in the report areas listed in Component placement.
- Do one of the following to open the Create Crosstab wizard:
- Click Insert > Crosstab on the menu bar.
- Click the Insert Crosstab button on the Insert toolbar.
- If you are inserting the crosstab into a web report or a library component, you can also drag Crosstab from the Toolbox panel to display the wizard.
- In the Data screen of the wizard,
- If you are inserting a crosstab into a page report, define or select the dataset on which the crosstab will be created.
- New
If checked, the crosstab will be built on a new dataset created from the catalog resources.
- Existing
If checked, specify the dataset in the current report from which the crosstab will be created.
- Current
If checked, the crosstab will be built on the dataset which is used by its parent.
- If you are inserting a crosstab into a web report or a library component select a business view in the current catalog on which the crosstab will be created.
- In the Display screen, add the required fields from the Resources box to the Columns and Rows boxes respectively to make them displayed on the columns and rows of the crosstab. For the added fields, you can specify their display names in the Label column which will label the rows and columns (by default the Label column is blank and no label will be created for the rows and columns), the background color in the Color column, set the sorting manner of the field values by clicking , and adjust their display order by clicking or . Then, add the fields as aggregate fields to the Summaries box and specify the aggregate functions and labels for the added fields. If necessary, click the Comparison Function button to set the comparison function for the aggregate fields. If the crosstab is inserted into a page report, you can also create some crosstab formulas and add them as aggregate fields so as to apply custom aggregate functions in the crosstab.
If you are inserting a crosstab into a web report or a library component, you can also specify a title for the crosstab in the Title text field.
- To apply some filters to the crosstab so as to reduce the data displayed in the crosstab, go to the Filter screen and define the filter conditions. If you are inserting the crosstab into a web report or a library componen, you can select a predefined filter of the specified business view if there is from the Filter drop-down list to apply, or select User Defined in the list to define a new filter. For how to define a filter, refer to Filtering the data.
- In the Layout screen, specify the layout of the crosstab.
- In the Style screen, set a style for the crosstab.
If you have specified to insert the crosstab into a banded object in a page report, by default the crosstab will inherit its parent's style. If you want to apply another style to the crosstab, uncheck the Inherit Style option and then select the required style from the Style box. For more information, see Inheriting the style from a data container.
- Click Finish to insert the crosstab.
If you have specified to insert the crosstab in the report body or tabular cell, the crosstab will be inserted there upon clicking the Finish button; otherwise, you need to click the mouse button in the destination once again in order to insert the crosstab there.
See also the Create Crosstab wizard for page report or web report/library component for detailed information about options in the wizard.
- Dragging a blank crosstab to a page report
- From the Toolbox panel, drag Crosstab to the destination in the report which allows the insertion of a crosstab, and a blank crosstab will then be created.
- In the Resource View panel, select the dataset you want to use in the crosstab from the dataset drop-down list. If you want to create a new dataset for the crosstab, select <Choose Data from...> from the list and new a dataset in the New Dataset dialog.
- Drag the required fields from the Resource View panel to the position of row header, column header or aggregate in the crosstab. Then the rows, columns and aggregates will be created.
When a crosstab has been created, you can customize its appearance and behavior by setting properties in the Report Inspector, which can be saved as a CSS style for future use (for details, see Creating a CSS style).
Note:
- When you want to create a crosstab on a hierarchical data source, pay attention to the unique features of HDS. For details, refer to Developing reports from HDS.
- When you insert a crosstab into a banded report with the dataset inherited from the banded report, you cannot insert the crosstab into the BandedPageHeader and BandedPageFooter panel.