Chapter Contents

Previous

Next
SAS Companion for UNIX Environments

Introduction to External Files and Devices

At times during a SAS session, you might want to use external files, that is, files that contain data or text or files in which you want to store data or text. These files are created and maintained by the operating system, not by the SAS System.

You can use external files in a SAS session to

For the SAS System, external files and devices can serve both as sources of input and as receivers of output. The input can be either raw data to be read in a DATA step or SAS statements to be processed by the SAS System. The output can be

You might also want to use peripheral devices such as a printer, plotter, or your own terminal. UNIX treats these I/O devices as if they were files. Each device is associated with a file, called a special file, which is treated as an ordinary disk file. When you write to a special file, the associated device is automatically activated. All special files reside in the dev directory or its subdirectories. Although there are some differences in how you use the various devices, the basic concept is the same for them all.

UNIX also enables you to use pipes to send data to and from operating system commands as if they were I/O devices.

The rest of this chapter describes how to specify an external file or device within a SAS session. Routing Output describes now to send the SAS log and SAS procedure output to an external file.

If you need to access an external file containing a transport data library, refer to Moving and Accessing SAS Files across Operating Environments.


Chapter Contents

Previous

Next

Top of Page

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