Accessing a SAS Library

Telling SAS Where the SAS Library Is Located

No matter which operating environment you are using, to access a SAS library, you must tell SAS where it is. You can do this in the following ways:
  • directly specify the operating environment's physical name for the location of the SAS library. The physical name must conform to the naming conventions of your operating environment, and it must be enclosed in quotation marks. For example, in the SAS windowing environment, the following DATA statement creates a data set named MYFILE:
    data 'c:\my documents\sasfiles\myfile';
  • assign a SAS libref (library reference), which is a SAS name that is temporarily associated with the physical location name of the SAS library.

Get Step-by-Step Programming with Base SAS 9.4 now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.