[SOLVED] Help creating subtotal with a computed alphanumeric field
I have the following output from a procedure I am working on: STATE WORK_DONE TOTAL_TM COUNT AVE_TM South Dakota Light 26:21 18 01:27 Heavy 28:04 1 28:04 Nebraska Light 63:23 41 01:32 Medium 62:39 1 62:39 Heavy 35:55 1 35:55
This is my code for the table:
DEFINE FUNCTION TMFM (TOTMIN/I10) -* CALCULATE HOURS HR/I2 = TOTMIN/60;
-* CALCULATE MINUTES MIN/I2 = TOTMIN -(HR*60) ;
-* FORMAT TO HH:MM TMFM/A5 = EDIT(HR)||':'||EDIT(MIN);
END
TABLE FILE RESULTS SUM COMPUTE TOTAL_TM/A5 = TMFM(SUM.TOTAL_MIN); CNT.TOTAL_MIN COMPUTE AVE_TM/A5 = TMFM(AVE.TOTAL_MIN); BY STATE BY WORK_DONE
END
Now I want to do a subtotal for each TOTAL_TM, COUNT, AVE_TM. If I do a 'ON STATE RECOMPUTE', all I see is the Total count for each state. How do I go about re-adding all the 'COMPUTE' for the alpha numeric field.This message has been edited. Last edited by: Kerry,
WebFOCUS 7.6 Windows, All Outputs
February 11, 2011, 10:58 AM
Doug
Check out SUBTOTAL, SUB-TOTAL, COLUMN-TOTAL, ROW-TOTAL, etc. And note that numeric fields are required for totaling. F! (Help) is a good place to start while waiting for some WebFOCUS training.
February 11, 2011, 11:44 AM
WFnoob
quote:
Originally posted by Doug: Check out SUBTOTAL, SUB-TOTAL, COLUMN-TOTAL, ROW-TOTAL, etc. And note that numeric fields are required for totaling. F! (Help) is a good place to start while waiting for some WebFOCUS training.
This is a non-answer.
WebFOCUS 7.6 Windows, All Outputs
February 11, 2011, 12:34 PM
j.gross
use
ON COUNTRY SUMMARIZE *
or
ON COUNTRY RECOMPUTE *
(Appears in 7702 new features -- but works at least as far back as 7.6.9)