August 2002
Intermediate to advanced
528 pages
10h 12m
English
The COMPUTE command is often used with the BREAK command and is used to calculate subtotals at breakpoints because summary totals are a very desirable report feature. The COMPUTE command, however, cannot be used without a complimentary BREAK command and is often confused with the group functions. In essence, they compute the same value. The difference is that the COMPUTE command allows the display of the detail (or grouped) records, while the GROUP BY clause used with the function compresses them into a single row.
The COMPUTE command is a format command, and it will reside in memory until cleared with the CLEAR COMPUTES command or until over-written with a new command. The structure of the command is as follows:
Compute value(s) ...