Chapter Contents

Previous

Next
The REPORT Procedure

Example 8: Condensing a Report into Multiple Panels


Procedure features:
PROC REPORT statement options:
FORMCHAR=
HEADLINE
LS=
PANELS=
PS=
PSPACE=
BREAK statement options:
SKIP
Other features:
SAS system option FORMCHAR=
Data set: GROCERY
Formats: $MGRFMT. and $DEPTFMT.

The report in this example





Program

libname proclib 'SAS-data-library';
options nodate pageno=1 linesize=80 pagesize=60
        fmtsearch=(proclib);
 Note about code
proc report data=grocery nowd headline
            formchar(2)='~'
            panels=99 pspace=6
            ls=64 ps=18;











 Note about code
   column manager department sales;




 Note about code
   define manager / order
                    order=formatted
                    format=$mgrfmt.;
   define department / order
                 order=internal
                 format=$deptfmt.;
   define sales / format=dollar7.2;
                  





 Note about code
   break after manager / skip;

 Note about code
   where sector='nw' or sector='sw';
   title "Sales for the Western Sectors";
run;


Output
[HTML Output]  

PANELS= has no affect on the HTML or Printer Output.

                Sales for the Western Sectors                 1

 Manager  Department    Sales      Manager  Department    Sales
 ~~~~~~~~~~~~~~~~~~~~~~~~~~~~      ~~~~~~~~~~~~~~~~~~~~~~~~~~~~
 Adams    Paper        $40.00                                  
          Canned      $225.00      Reveiz   Paper        $60.00
          Meat/Dairy  $350.00               Canned      $420.00
          Produce      $80.00               Meat/Dairy  $600.00
                                            Produce      $30.00
 Brown    Paper        $45.00                                  
          Canned      $230.00      Taylor   Paper        $53.00
          Meat/Dairy  $250.00               Canned      $120.00
          Produce      $73.00               Meat/Dairy  $130.00
                                            Produce      $50.00
 Pelfrey  Paper        $45.00                                  
          Canned      $420.00                                  
          Meat/Dairy  $205.00                                  
          Produce      $76.00                                  


Chapter Contents

Previous

Next

Top of Page

Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.