Declaration¶
Source position: fpexprpars.pp line 666
type
TAggregateMax = class(TAggregateExpr)
public
procedure InitAggregate;
procedure UpdateAggregate;
end;
Description¶
The TAggregateMax class implements the maximum aggregate function, which finds the largest value among all processed values. It extends TAggregateExpr to provide maximum-specific aggregation logic.
The class maintains an internal state that tracks the maximum value encountered so far during the aggregation process. The first value encountered is used as the initial maximum, and subsequent values are compared to update the maximum when larger values are found.
The maximum function works with numeric types (integers, floats, currency) and can also compare string and date/time values using appropriate comparison logic for each data type.
Methods¶
| Member | Visibility | Description |
|---|---|---|
| InitAggregate | public | Initialize maximum aggregation |
| UpdateAggregate | public | Update maximum aggregate with new value |
See also¶
| Name | Description |
|---|---|
| TFPExprNode | Class for representing nodes in expression trees |