Chapter Contents

Previous

Next
SAS/ACCESS Software for Relational Databases: Reference

SAS Data Sets

This section describes the SAS data sets used in some of the examples. It provides the SAS statements that create each data set and shows the output from the PRINT procedure. The code that creates these data sets is available in the GENSAMP.SAS file that is included with your SAS/ACCESS software.


DLIB.BIRTHDAY SAS Data File

The SAS data file DLIB.BIRTHDAY is created with the following SAS statements:

libname dlib 'Your-SAS-data-library';
data dlib.birthday;
   input empid birthdat date7.
         lastname $18.
         firstnam $15.
         phone $4.;
         datalines;
459287 05JAN39 RODRIGUES       JUAN     5879
127845 25DEC48 MEDER           VLADIMIR 6231
254896 06APR54 TAYLOR-HUNYADI  ITO      0231
;

The following PRINT procedure lists the data shown in Data in SAS Data File DLIB.BIRTHDAY:

proc print data=dlib.birthday;
   format birthdat date9.;
   title 'DLIB.BIRTHDAY Data File';
run;

Data in SAS Data File DLIB.BIRTHDAY
              DLIB.BIRTHDAY Data File                            

 OBS    EMPID   BIRTHDAT    LASTNAME        FIRSTNAM  PHONE

  1    459287   05JAN1939   RODRIGUES       JUAN      5879
  2    127815   25DEC1948   MEDER           VLADIMIR  6231
  3    254196   06APR1954   TAYLOR-HUNYADI  ITO       0231


DLIB.OUTOFSTK SAS Data File

The SAS data file DLIB.OUTOFSTK is created with the following SAS statements:

libname dlib 'Your-SAS-data-library';
data dlib.outofstk;
   input fibernam $8. fibernum;
   datalines;
olefin   3478
gold     8934
dacron   4789
;

The following PRINT procedure lists the data shown in Data in SAS Data File DLIB.OUTOFSTK:

proc print data=dlib.outofstk;
   title 'SAS Data File DLIB.OUTOFSTK';
run;

Data in SAS Data File DLIB.OUTOFSTK
            SAS Data File DLIB.OUTOFSTK

                OBS    FIBERNAM    FIBERNUM

                 1      olefin       3478
                 2      gold         8934
                 3      dacron       4789


DLIB.TEMPEMPS SAS Data File

The SAS data file DLIB.TEMPEMPS is created with the following PROC SQL statements:

libname dlib 'Your-SAS-data-library';
proc sql;
   create table dlib.tempemps 
      (label='Student interns',
       empid num, hiredate date format=date7., 
             dept char(6), gender char(1),
            lastname char(18), firstnam char(15), 
            middlena char(15), familyid num);

 insert into dlib.tempemps
      values(765111,'04MAY98'd,'CSR011','M',
             'NISHIMATSU-LYNCH','RICHARD',
             'ITO',677890)
      values(765112,'04MAY98'd,'CSR010','M',
             'SMITH','ROBERT','MICHAEL',234967)
      values(219776,'15APR98'd,'ACC024','F',
             'PASTORELLI','ZORA',null,.)
      values(245233,'10APR98'd,'ACC013',' 
             ','ALI','SADIQ','H.',.)
      values(245234,'10APR98'd,'ACC024','F',
             'MEHAILESCU','NADIA','P.',.)
      values(326721,'01MAY98'd,'SHP002','M',
             'CALHOUN','WILLIS','BEAUREGARD',.);

quit;

The following PRINT procedure lists the data shown in Data in DLIB.TEMPEMPS:

options ls=120;
proc print data=dlib.tempemps;
   title 'DLIB.TEMPEMPS Data File';
run;

Data in DLIB.TEMPEMPS
                                                DLIB.TEMPEMPS Data File

        OBS     EMPID    HIREDATE     DEPT     GENDER    LASTNAME            FIRSTNAM    MIDDLENA      FAMILYID

         1     765111    04MAY98     CSR011      M       NISHIMATSU-LYNCH    RICHARD     ITO            677890
         2     765112    04MAY98     CSR010      M       SMITH               ROBERT      MICHAEL        234967
         3     219776    15APR98     ACC024      F       PASTORELLI          ZORA                            .
         4     245233    10APR98     ACC013              ALI                 SADIQ       H.                  .
         5     245234    10APR98     ACC024      F       MEHAILESCU          NADIA       P.                  .
         6     326721    01MAY98     SHP002      M       CALHOUN             WILLIS      BEAUREGARD          .


DLIB.RATEOFEX SAS Data File

The SAS data file DLIB.RATEOFEX is created with the following SAS statements:

libname dlib 'Your-SAS-data-library';
data dlib.rateofex;
   input updated date7.
         currency & $15.
         fgnindol : 8.
         dolinfgn : 11.
         country & $20.;
   format updated date9.
          currency $15.
          fgnindol 8.6
          dolinfgn 11.6
          country $20.;
   datalines;
28JUL93 peso    1.01 0.99 Argentina
28JUL93 dollar    0.7457 1.3410 Australia
more data lines
;

The following PRINT procedure lists the data shown in Data in SAS Data File DLIB.RATEOFEX:

proc print data=dlib.rateofex;
   title 'Data in SAS Data File DLIB.RATEOFEX';
run;

Data in SAS Data File DLIB.RATEOFEX
                      Data in SAS Data File DLIB.RATEOFEX

 OBS  UPDATED  CURRENCY            FGNINDOL     DOLINFGN  COUNTRY

   1  28JUL98  4 peso              1.010000     0.990000  Argentina
   2  28JUL98  4 dollar            0.745700     1.341000  Australia
   3  28JUL98  4 schilling         0.095940    10.420000  Austria
   4  28JUL98  4 dinar             2.652200     0.377100  Bahrain
   5  28JUL98  4 franc             0.032780    30.510000  Belgium
   6  28JUL98  4 cruzeiro          0.000260  3872.000000  Brazil
   7  28JUL98  4 pound             1.919500     0.521000  Britain
   8  28JUL98  4 dollar            0.841400     1.188500  Canada
   9  28JUL98  4 peso              0.002835   352.750000  Chile
  10  28JUL98  4 renminbi          0.182815     5.470000  China
  11  28JUL98  4 peso              0.001722   580.640000  Columbia
  12  28JUL98  4 krone             0.175400     5.700500  Denmark
  13  28JUL98  4 sucre             0.000693  1443.000000  Ecuador
  14  28JUL98  4 markka            0.246490     4.057000  Finland
  15  28JUL98  4 franc             0.199980     5.000500  France
  16  28JUL98  4 mark              0.675400     1.480500  Germany
  17  28JUL98  4 drachma           0.005491   182.100000  Greece
  18  28JUL98  4 dollar            0.129190     7.740500  Hong Kong
  19  28JUL98  4 forint            0.013139    76.110000  Hungary
  20  28JUL98  4 rupee             0.035650    28.050000  India
  21  28JUL98  4 rupiah            0.000493  2029.510000  Indonesia
  22  28JUL98  4 punt              1.802600     0.554800  Ireland
  23  28JUL98  4 shekel            0.406500     2.460000  Israel
  24  28JUL98  4 lira              0.000892  1120.500000  Italy
  25  28JUL98  4 yen               0.007843   127.500000  Japan
  26  28JUL98  4 dinar             1.527700     0.654600  Jordan
  27  28JUL98  4 dinar             3.420600     0.292400  Kuwait
  28  28JUL98  4 pound             0.000503  1990.000000  Lebanon
  29  28JUL98  4 ringgit           0.400000     2.500300  Malaysia
  30  28JUL98  4 lira              3.344500     0.299000  Malta
  31  28JUL98  4 peso              0.000321  3114.510000  Mexico
  32  28JUL98  4 guilder           0.598900     1.669800  Netherlands
  33  28JUL98  4 dollar            0.546100     1.831200  New Zealand
  34  28JUL98  4 krone             0.171800     5.819500  Norway
  35  28JUL98  4 rupee             0.040000    25.000000  Pakistan
  36  28JUL98  4 new sol           0.839000     1.190000  Peru
  37  28JUL98  4 peso              0.040900    24.450000  Philippines
  38  28JUL98  4 zloty             0.000077  12959.01000  Poland
  39  28JUL98  4 escudo            0.007949   125.800000  Portugal
  40  28JUL98  4 riyal             0.267380     3.740000  Saudi Arabia
  41  28JUL98  4 dollar            0.619000     1.615500  Singapore
  42  28JUL98  4 rand              0.362300     2.759800  South Africa
  43  28JUL98  4 won               0.001270   787.400000  South Korea
  44  28JUL98  4 peseta            0.010612    94.230000  Spain
  45  28JUL98  4 krona             0.186000     5.376000  Sweden
  46  28JUL98  4 franc             0.763400     1.310000  Switzerland
  47  28JUL98  4 dollar            0.039714    25.180000  Taiwan
  48  28JUL98  4 baht              0.039450    25.350000  Thailand
  49  28JUL98  4 lira              0.000144  6938.000000  Turkey
  50  28JUL98  4 dirham            0.272300     3.672500  United Arab
  51  28JUL98  4 new peso          0.000321  3120.010000  Uruguay
  52  28JUL98  4 bolivar           0.015130    66.090000  Venezuela

Note:    If you want to run the examples in this book, access your online HELP system, or contact your SAS Software Representative for information about how to access the sample library files.  [cautionend]


Chapter Contents

Previous

Next

Top of Page

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