SQL/MX Report Writer Guide

Customizing a Report
HP NonStop SQL/MX Report Writer Guide527194-002
4-54
Calculating Subtotals
When using the SUBTOTAL command, consider these points:
You can specify the column identifier values in any order.
You must define the break groups with a BREAK ON command.
You must specify in one SUBTOTAL command all columns you want to subtotal
over the same break group. You can specify additional SUBTOTAL commands for
other break groups.
Figure 4-20. A Report With Subtotals (Page 2 of 2)
1670065.00
Supplier
:
8
ATTRACTIVE CORP,
CHICAGO,
ILLINOIS
Page 2
VST0421.vsd
End of Summary
Supplier
: 6
MAGNETICS INC,
LEXINGTON, MASS
Supplier Parts Summary
Part Number
Available
Units
Unit Cost
(dollars)
Total Cost
(dollars)
Estimated Profit
2002
2405
3220
5100
4102
3210
2712
3314
6540
3237
1100.00
450.00
470.00
20.00
100.00
3542000.00
1220400.00
1557580.00
130800.00
323700.00
1288000.00
935640.00
811930.00
52320.00
161850.00
5504
3486440.00
2630 75.00
197250.00
236700.00
6971730.00
4102
5101
5100
5103
3237
6540
2400
3328
19.00
105.00
135.00
265.00
124260.00
339885.00
324000.00
881920.00
58860.00
145665.00
156000.00
449280.00
809805.00
Supplier
:
15
DATADRIVE CORP,
DALLAS,
TEXAS
4102
3210
3103
5100
3300
3314
6540
3237
3300.00
450.00
21.00
95.00
10890000.00
1491300.00
137340.00
307515.00
2970000.00
878210.00
45780.00
178035.00
5504
5103
5101
5505
14929295.00
5420485.00
2400
3328
2630
3830
125.00
250.00
78.00
200.00
300000.00
832000.00
205140.00
766000.00
180000.00
228810.00
440450.00
499200.00
116601265.00
41603715.00