SAN - Sample Report

The following common library programs: FOC1030A, FOC1030B and FOC1030C, illustrate how to combine two years of annual data (2000 and 1995) into a single report. The resulting report can be downloaded and brought into a spreadsheet package such as EXCEL to produce graphs and charts.  

 

Select the SAN 00 file (2000) and execute common library FOCEXEC: FOC1030A.   

 

EX SAN

-* SINCE THE FIELD NAMES ARE THE SAME FOR BOTH YEARS, IT IS NECESSARY

-* TO RENAME THE FIELDS SO THAT WHEN THEY ARE COMBINED IN A HOLD

-* FILE THE NAMES ARE DIFFERENT.

END

TABLE FILE SAN

SUM san:salary as SAL95

    CNT.san:salary as cnt95

BY SAN:CBID

ON TABLE HOLD AS PERMSML

END

 

Exit FOCUS, and select the SAN 95 file (1995) and then execute the common library FOCEXEC: FOC1030B.

 

EX SAN

-* SINCE THE FIELD NAMES ARE THE SAME FOR BOTH YEARS, IT IS NECESSARY

-* TO RENAME THE FIELDS SO THAT WHEN THEY ARE COMBINED IN A HOLD

-* FILE THE NAMES ARE DIFFERENT.

END

TABLE FILE SAN

SUM san:salary as SAL00

    CNT.san:salary as cnt00

BY SAN:CBID

ON TABLE HOLD AS PERMLRG

END

 

After executing FOC1030B, execute common library FOC1030C to combine the data in PERMSML and PERMRPT.

 

MATCH FILE PERMSML

SUM sal95 cnt95

BY san:cbid

RUN

FILE PERMLRG

SUM SAL00 CNT00

BY SAN:CBID

AFTER MATCH HOLD AS PERMRPT OLD-OR-NEW

END

-*

TABLE FILE PERMRPT

PRINT sal95 as '1995 salaries'

      cnt95 as '1995 positions'

      sal00 as '2000 salaries'

      cnt00 as '2000 positions'

HEADING CENTER

"THE CALIFORNIA STATE UNIVERSITY"

"COMPARISON OF SALARIES AND POSITIONS FOR 1995 AND 2000"

"COMMON focexec:  FOC1030C"

END

 

The following is only an excerpt from the actual report.

 

              THE CALIFORNIA STATE UNIVERSITY

COMPARISON OF salaries and positions for 1995 AND 2000

                  COMMON FOCEXEC: FOC1030C

 

                         1995                      2000

CBID     1995 SALARIES   PSNS     2000 SALARIES    PSNS

----     -------------   -----    -------------    ----

C99         $51,748.97      18       $13,574.00       7

E99      $1,472,579.46    2973      $625,492.34    1823

M80     $11,269,961.89    2202    $9,303,701.24    2396

M98        $269,273.00      26      $209,592.68      25

R01        $390,892.75     111      $482,425.00     144

R02        $662,038.10     318      $689,659.61     424

R03     $59,011,779.38   18951   $52,160,731.36   22164

R04      $4,616,804.52    1638    $3,646,705.78    1608

R05      $3,013,326.25    1568    $3,013,847.36    1989

R06      $2,291,198.74     760    $1,949,397.05     854

R07     $12,481,259.81    6609   $10,592,933.46    8296

R08        $734,447.45     267      $631,002.00     235

R09      $9,380,832.15    3560    $6,765,001.83    3272