count(
count(
FIELD
)

The count( function counts all non-empty instances of a line item field in the current record.

Parameters

This function has one parameter:

field – is the line item field you want to count. You may use the Ω symbol (type option-Z) at the end of the field name to indicate that the fields to be added are line items, however, that is not required. The field name may be quoted, but that is not required.

Description

The count( function counts all non-empty instances of a line item field in the current record. This is similar to the sum( function, but counts instead of adds.

This example computes the average of the Score line item fields, Score1, Score2, Score3, etc.

    100*sum(ScoreΩ)/count(ScoreΩ)

This could also be written as:

    100*sum("ScoreΩ")/count("ScoreΩ")

or

    100*sum("Score")/count("Score")

See Also

- emptylineitemnumber( -- returns the numeric suffix of the first matching line item field that is empty (if any).
- Line Item Fields -- are used for repeating items within a record
- sum( -- adds up all instances of a line item field in the current record.

History

Version | Status | Notes
10.0 | New | New in this version.