Assuming you have appropriate dictionaries called : NBR, DAYS,
TYPE,
and HRS that return the appropriate attribute; you can create
dictionaries called say... T1 , T2, and T3 that return the HRS field
only if the TYPE is equal to a specific value - I used the "A"
correlative.
:ED DICT TESTOR T1
001 A
002 0
003 T1
004
005
006
007
008 A;IF N(TYPE)="T1" THEN N(HRS)ELSE ""
009 R
010 5
The following English statement then produces a reasonable facsimle
of
your desired output.
:SORT TESTOR BY NBR BREAK-ON NBR TOTAL T1 TOTAL T2 TOTAL T3 TOTAL HRS
ID-SUPP DET-SUPP
PAGE 1 09:41:26 16
JUN
2009
No... T1... T2... T3... Hrs..
001 3 0 0 3
002 0 1 0 1
003 1 0 5 6
4 1 5 10
5 ITEMS LISTED.