Operator Function: aggregateRow - Aster Execution Engine

Teradata Aster® Developer Guide

Product
Aster Execution Engine
Release Number
7.00.02
Published
July 2017
Language
English (United States)
Last Update
2018-04-13
dita:mapPath
xnl1494366523182.ditamap
dita:ditavalPath
Generic_no_ie_no_tempfilter.ditaval
dita:id
ffu1489104705746
lifecycle
previous
Product Category
Software

A NonDecomposableAggregatorFunction must implement aggregateRow method. The aggregateRow computes final results from input rows. The function is given a RowView, which is an abstract of table row. This row is provided by RowIterator and is run by the aggregate execution engine. This function does not return any value. You should define the instance variable to store the final results as ValueHolder. You should implement the method to update final results based on each new row input until the end of the current partition.

Below is an example of a simple function that counts the number of rows for each input partition. The aggregateRow method computes final counts from the input rows.

// Count the input row.
public void aggregateRow(RowView row) {
   count_++;
}