Group By Rollup (Teradata Database) - Teradata Warehouse Miner

Teradata® Warehouse Miner™ User Guide - Volume 2ADS Generation

Teradata Warehouse Miner
Release Number
November 2018
English (United States)
Last Update
Product Category

If the Group By Style on the analysis parameters tab is set to User specified, a Group By Rollup element may be dragged onto the empty node under the Group By Clause, giving the following result. If User specified is not checked, a warning is given when the Group By Rollup element is applied that the option will be automatically checked.

Columns can be moved into the folder titled Expressions (but not expressions or column positions), leading to a comma separated list of the columns that define a rollup of report rows across a single logical dimension. If only one column is specified, it is equivalent to an ordinary Group By clause.

In the following example with the tutorial data table twm_customer, a group by rollup of customer_count over a single dimension defined and ordered by gender and marital_ status is requested.

Selected variables and expert options are shown below.
Variable Creation > Input > expert options: Group By Clause > Group By Rollup

The resulting data is listed in the following table.

Group By Rollup: Resulting Data
gender marital_status customer_count
F   418
F 1 159
F 2 189
F 3 30
F 4 40
M   329
M 1 117
M 2 164
M 3 18
M 4 30

The blank spaces in the answer table above represent null values that signify the empty set rather than information that is missing. Through this technique, aggregations at many different levels are shown in a single answer table.

There are no special properties for the Group By Rollup element.