![]() |
![]() |
Doing More with Remote Connect |
When you establish a connection to a remote host, the remote host invokes a SAS session. The remote SAS session has the automatically-defined libraries associated with it (WORK, SASUSER, and so on), as well as any libraries and options that are defined by the SAS session's AUTOEXEC file. See the SAS companion documentation for your operating environment for more information on AUTOEXEC files.
You might want to assign librefs to libraries on the remote host other than the ones automatically assigned. You can assign librefs on a remote host using SAS/ASSIST software by following these directions.
Follow this
selection path:Tasks Remote Connect
Transfer Data
Utilities
Assign librefThe
Assign a New Libref window appears.
Assign a New Libref Window
In the Libref field, type the libref you want to use to reference the library.
In the Name of the SAS data library field, type the path to the library, using the naming conventions of the remote operating environment.
Select Remote. If more than one remote connection is open, select the remote connection to the host on which you want to assign this libref.
If the libref assignment is successful, a message appears to inform you of this fact; select Goback to return to the WorkPlace menu. If the assignment is not successful, select View the log to read the error messages and diagnose the problem. If you do not understand the error messages, contact the SAS Support Consultant at your site.
If you find that you are frequently using this method to access the same library, or if assigning librefs on your remote host requires special options, you should consider having that library automatically assigned upon startup of the remote SAS session by adding appropriate LIBNAME statements to the remote host's AUTOEXEC file. Contact your SAS Support Consultant for details.
If you are going to download table information (as in
the following section) to set up SAS/ASSIST tasks for remote execution, you
must have a library on your local SAS session that has the same libref as
the remote library containing the desired table. You can assign a libref on
the local SAS session by following this selection path:Tasks Setup
File Management
SAS Data
Libraries
Assign a new libref Give your new library the same libref as the remote library,
and assign it to any library on the local host.
Note that SAS/ASSIST software will not download table
information for a remote libref.table-name if
a table with the same libref.table-name already
exists on the local host. This feature prevents overwriting an existing table.
If you need to download table information for a remote table that has the
same libref and table name as an existing table on the local host, you can
temporarily clear the libref on the local host and then re-assign it when
you are finished. To clear a local libref, follow this selection path:Tasks Setup
File Management
SAS Data
Libraries
Clear a librefSelect
the libref to be cleared in the Select a Library
window and select OK. Alternatively, you can use
the Explorer to change the libref or rename the table.
![]() |
![]() |
Copyright © 2012 by SAS Institute Inc., Cary, NC, USA. All rights reserved.