Example of vertically pivoting data

In this example, the Pivot Enterprise stage is set up to vertically pivot some data and aggregate a monthly average of sales.

The following tables provide examples of data before and after a vertical pivot operation.
Table 1. Input data for vertical pivot operation
REPID last_name Q_sales
100 Smith 1234.08
100 Smith 1456.80
100 Smith 1578.00
101 Yamada 1245.20
101 Yamada 1765.00
101 Yamada 1934.22
Table 2. Out put data for vertical pivot operation
REPID last_name Q_sales (January) Q_sales1 (February) Q_sales2 (March) Q_sales_average
100 Smith 1234.08 1456.80 1578.00 1412.96
101 Yamada 1245.20 1765.00 1934.22 1648.14
The following screen capture shows the settings for a vertical pivot on the Pivot Definitions tab of the Stage page.
Figure 1. Example of vertical pivot settings on the Pivot Definitions tab
Shows the settings for a Pivot Definitions tab configured for a vertical pivot to generate multiple columns containing the vertically pivoted data, and a column containing an aggregated average.
The following screen capture shows the settings for a vertical pivot operation on the Mapping tab of the Output page.
Figure 2. Mapping tab
Shows the settings for a vertical pivot operation on the Mapping tab of the Output page to output the pivoted data, the pivot index, the REPID column, and the Last_name column.