Return Values

Unlike all other database APIs, the values returned by E@DBAGGREGATE are not part of the regular file record area. In fact, nothing related to the aggregate range routines alters the contents of the file record area in any way. Because the SUM function can potentially return a value which overflows the boundaries of the field being derived, all return values are dimensioned to the maximum allowable field size of 18 digits. The number of decimal positions is inherited from the database field. The naming convention for these return value fields is:

D<Prefix>#<Function>#<FieldName>

where <Prefix> is the prefix associated with the database file, <Function> is the two-character abbreviation for the function performed by the aggregate API (AV, MA, MI, or SU), and <FieldName> is the name of the field used in the function.