Previous Page | Next Page

The CALENDAR Procedure

Example 5: Schedule Calendar, Blank or with Holidays


Procedure features:

PROC CALENDAR statement options:

FILL

HOLIDATA=

INTERVAL=WORKDAY

DUR statement

HOLIDUR statement

HOLISTART statement

HOLIVAR statement


This example produces a schedule calendar that displays only holidays. You can use this same code to produce a set of blank calendars by removing the HOLIDATA= option and the HOLISTART, HOLIVAR, and HOLIDUR statements from the PROC CALENDAR step.


Program

 Note about code
data acts;
   input sta : date7. act $ 11-30 dur;
   datalines;
01JAN97   Start                 0
31DEC97   Finish                0
;
 Note about code
data holidays;
   input sta : date7. act $ 11-30 dur;
   datalines;
01JAN97   New Year's            1
28MAR97   Good Friday           1
30MAY97   Memorial Day          1
04JUL97   Independence Day      1
01SEP97   Labor Day             1
27NOV97   Thanksgiving          2
25DEC97   Christmas Break       5
;
 Note about code
options nodate pageno=1 linesize=132 pagesize=30;
 Note about code
proc calendar data=acts holidata=holidays fill interval=workday;
 Note about code
   start sta;
   dur dur;
 Note about code
   holistart sta;
   holivar act;
   holidur dur;
 Note about code
   title1 'Calendar of Holidays Only';
run;

Output: Listing

Schedule Calendars with Holidays Only

 Note about figure
                                                     Calendar of Holidays Only                                                     1

  -------------------------------------------------------------------------------------------------------------------------------
  |                                                                                                                             |
  |                                                        January  1997                                                        |
  |                                                                                                                             |
  |-----------------------------------------------------------------------------------------------------------------------------|
  |     Sunday      |     Monday      |     Tuesday     |    Wednesday    |    Thursday     |     Friday      |    Saturday     |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |                 |                 |                 |        1        |        2        |        3        |        4        |
  |                 |                 |                 |***New Year's****|                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |        5        |        6        |        7        |        8        |        9        |       10        |       11        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |       12        |       13        |       14        |       15        |       16        |       17        |       18        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |       19        |       20        |       21        |       22        |       23        |       24        |       25        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |       26        |       27        |       28        |       29        |       30        |       31        |                 |
  |                 |                 |                 |                 |                 |                 |                 |
  -------------------------------------------------------------------------------------------------------------------------------
                                                     Calendar of Holidays Only                                                     2

  -------------------------------------------------------------------------------------------------------------------------------
  |                                                                                                                             |
  |                                                       February  1997                                                        |
  |                                                                                                                             |
  |-----------------------------------------------------------------------------------------------------------------------------|
  |     Sunday      |     Monday      |     Tuesday     |    Wednesday    |    Thursday     |     Friday      |    Saturday     |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |                 |                 |                 |                 |                 |                 |        1        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |        2        |        3        |        4        |        5        |        6        |        7        |        8        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |        9        |       10        |       11        |       12        |       13        |       14        |       15        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |       16        |       17        |       18        |       19        |       20        |       21        |       22        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |       23        |       24        |       25        |       26        |       27        |       28        |                 |
  |                 |                 |                 |                 |                 |                 |                 |
  -------------------------------------------------------------------------------------------------------------------------------
                                                     Calendar of Holidays Only                                                    12

  -------------------------------------------------------------------------------------------------------------------------------
  |                                                                                                                             |
  |                                                       December  1997                                                        |
  |                                                                                                                             |
  |-----------------------------------------------------------------------------------------------------------------------------|
  |     Sunday      |     Monday      |     Tuesday     |    Wednesday    |    Thursday     |     Friday      |    Saturday     |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |                 |        1        |        2        |        3        |        4        |        5        |        6        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |        7        |        8        |        9        |       10        |       11        |       12        |       13        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |       14        |       15        |       16        |       17        |       18        |       19        |       20        |
  |                 |                 |                 |                 |                 |                 |                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |       21        |       22        |       23        |       24        |       25        |       26        |       27        |
  |                 |                 |                 |                 |*Christmas Break*|*Christmas Break*|                 |
  |-----------------+-----------------+-----------------+-----------------+-----------------+-----------------+-----------------|
  |       28        |       29        |       30        |       31        |                 |                 |                 |
  |                 |*Christmas Break*|*Christmas Break*|*Christmas Break*|                 |                 |                 |
  -------------------------------------------------------------------------------------------------------------------------------

Previous Page | Next Page | Top of Page