Commands under OpenVMS |
OpenVMS specifics: | valid values for file-specification and encoding-value |
Syntax | |
Details | |
Example | |
See Also |
Syntax |
INCLUDE <file-specification><ENCODING='encoding-value'><option-list> |
a single filename. SAS searches for the file in the current directory. If you enclose the filename in quotation marks, SAS uses the filename exactly as you specify it. If you do not enclose the filename in quotation marks and if you do not specify a filename extension, SAS searches for file-specification.sas .
an entire pathname. SAS does not assume any filename extensions, even if you do not enclose the pathname in quotation marks.
specifies the encoding to use when reading from the external file. The value for ENCODING= indicates that the external file has a different encoding from the current session encoding.
When you read data from an external file, SAS transcodes the data from the specified encoding to the session encoding.
For valid encoding values, see Encoding Values in SAS Language Elements in SAS National Language Support (NLS): Reference Guide.
names options for the INCLUDE command that are valid in all operating environments. For more information about these options, see the INCLUDE command in the Base SAS section in the online SAS Help and Documentation.
Details |
The INCLUDE command copies the entire contents of an external file into the current window.
If you do not specify a file-specification, then SAS uses the filename from the previous FILE or INCLUDE command. In this case, SAS first asks you if you want to overwrite the file. If you have not issued any FILE or INCLUDE commands, you receive an error message indicating no default file exists. For a list of default file types used for the INCLUDE command, see Default File Types.
Example |
Suppose you have previously specified the following FILENAME statement:
filename myfile '[mydir]oranges.dat';
The following INCLUDE command includes the file ORANGES.DAT in the Program Editor window:
include myfile
See Also |
Copyright © 2009 by SAS Institute Inc., Cary, NC, USA. All rights reserved.