min

Type

Statistical Operator

Purpose

The min operator finds the smallest value in a specified field among all the records that are processed. The result appears in the statistical summary areas of the report.

Syntax

VALUE : min [other statistical operators] ;|.

Returns

A value of the same type as the specified value. If the specified value is a Text field, min returns the lowest ASCII value.

Usage

There's an important difference between the statistical operator min and the relational statistical operator lowest of. min returns the lowest value in the specified field among the records being processed. lowest of returns the lowest value in the specified field among the records related to the records being processed.

Example

for MEMBERS ;

list records

LAST NAME in order ;

TOTAL DUE : item min .

end

 

This script tells DataEase: (1) Process all the MEMBERS records and list each member's LAST NAME in alphabetical order, and (2) list each member's TOTAL DUE and include the smallest TOTAL DUE amount in the report output.

The output from this script might look as follows:

 

Last Name

Total Due

Archer

$120.00

Christino

$210.00

Forrest

$75.00

Jones

$95.00

Morelli

$155.00

Perrault

$185.00

Min Total Due:

$75.00