
Operator
Purpose
Conditional Statistical Operators generate statistical information about specific conditions that occur in a set of records.
The DQL uses three Conditional Statistical Operators: item, count, and percent.
item returns a YES or NO answer indicating if the comparison is true or false.
count returns the number of true responses within all the specified records as well as specified groups.
percent returns the percentage of true responses (the number of true responses divided by the total number of records processed, multiplied by 100). percent also works at the group level.
In a script, the Conditional Statistical Operator is inserted after a list item that is compared to a specified value. The operator is separated from the comparison by a colon.
Example
TOTAL DUE ;
TOTAL DUE > 100 : item count percent .
This script tells DataEase: (1) Process all the MEMBERS records, (2) list each member's LAST NAME and TOTAL DUE, (3) for each member, display a YES or NO answer indicating if the member's TOTAL DUE is greater than $100, (4) display the total number of members whose TOTAL DUE is greater than $100, and (5) display the number of members that have a TOTALDUE greater than $100 as a percentage of all the members.
The output from this script arranged in alphabetical order by LAST NAME might look as follows:
Last Name |
Total Due |
Total over $100 |
Adams |
85.00 |
NO |
Albert |
120.00 |
YES |
Andersen |
120.00 |
YES |
Anderson |
70.00 |
NO |
Archer |
115.00 |
YES |
Baldwin |
100.00 |
YES |
Beauchamp |
35.00 |
NO |
Beauchamp |
85.00 |
NO |
Beecher |
85.00 |
NO |
Bennington |
135.00 |
YES |
Bickford |
135.00 |
YES |
Birnbaum |
65.00 |
NO |
Blake |
85.00 |
NO |
Borusiewicz |
100.00 |
NO |
... |
... |
... |
Count: 44
Percent: 23%
Product: DataEase for Windows 7.x. Written by George Washington 11/04/14 at 08:26:17
Product: DataEase 8 Reporter. Written by eduardo paez 02/05/14 at 14:40:11
Product: . Written by Marco Marchesi 15/02/16 at 14:50:46
Product: . Written by Grossi Gioacchino 18/11/19 at 14:33:44
Product: Dataease [{8}]FIVE. Written by Rainer 22/03/21 at 11:13:10
Product: Dataease [{8}]FIVE. Written by Rainer 08/06/21 at 14:12:40