Crosstab tables are a useful way to summarize information in a tabular format. A crosstab table is constructed by using the values of two table columns as row and column headers. A third column is used to obtain the crosstab table cell values. The cell values are a summarization of the rows that match both the row and column header values. For example, suppose we have the following table containing the original data:
The ‘Customer’ column is used as the row header, and the ‘Product’ column is used as the column header. The summarization is done on the ‘Quantity’ column. The resulting crosstab table is shown on the left:
The same information can obviously be generated by grouping on both the‘Customer’ and ‘Product’ columns, and by summarizing the ‘Quantity’ column. However, information is often more readable when presented in the tabular form, as in a crosstab table.
The next example changes the report table to a crosstab table. It uses the ‘Company’ and ‘Product’ columns as headers, and the ‘Quantity’ column as the details.
Additional attributes can be specified on the Options tab. These include foreground and background colors as well as font. A label for the column and row totals may be specified. By clicking the appropriate border in the ‘Crosstab Grid’ area you can define crosstab table border options. This allows you to provide attractive formatting for the crosstab table grid cells.
Both rows and columns can be sorted. Sorting is always done based on the header values. Optionally, the row header columns’ original column header can be retained. In this case, the original headers are used as the column header of the row header columns. The ‘Show Summary Headers’ option can be selected in order to see the column header names for the summary columns. If the ‘Summary Cells Side by Side’ option is selected, the summary header row appears just above the data cells; if the ‘Summary Cells Side by Side’ is not selected, a summary header column appears on the left. The text in the summary column header field can be modified by applying text formatting to those cells.
Copyright © 2023, InetSoft Technology Corp.