The STAT command combines the functions of the COUNT and SUM commands and also averages the value of a numeric attribute. The result is three values:
The total of the data in the numeric attribute
The average value of this data
The number of items selected
This command is generally used for analysis rather than reporting.
This query displays statistics about the sale amounts (AMOUNT) for the book whose code is N01:
>STAT ORDERS AMOUNT WITH BOOKCODE = "N01" STATISTICS OF AMOUNT: TOTAL = $2524.00 AVERAGE = $315.0050 COUNT = |
See Also