|SAS ODBC Driver User's Guide and Programmer's Reference|
Each data source can include multiple data libraries. (See SAS Data Libraries for information.) Therefore, you provide information about each library that you want to access.
This section describes how to use the Libraries page to define your data libraries. See Defining Libraries at Server Startup Time for information about an alternate way of defining data libraries.
Librariestab in the SAS ODBC Driver Configuration dialog to go to the Libraries page (Libraries Page). Supply the information described in the following steps. If at any point you want to clear all of the fields on the right side of the dialog and start again, select [Clear].
Namefield, enter a name for an existing physical SAS data library that you want to access. (For those who are familiar with SAS, this field corresponds to the libref in the SAS LIBNAME statement.) The name can be up to eight characters long. The first character must be a letter or an underscore. Subsequent characters can be letters, numeric digits, or underscores. Blanks and special characters are not allowed. For example, you might use the name
costto designate a library of cost-accounting data.
The SAS data library can include SAS data files, SAS data views, or both. See SAS Data Sets for more information.
Note: If you use an ODBC application that exports databases using one-level
names, you will need to define a library called
Host Filefield, enter the physical name of the library. This must be a valid pathname for the operating system that your data library is stored on. For example, for a library that is stored on a PC in the Windows environment,
c:\data\costacctwould be a valid pathname.
Descriptionfield, supply a description of the library, to remind yourself or other users of what the library contains.
Enginefield, enter the name of the SAS engine that is required for writing to and reading from this library. This is necessary only if you do not want the SAS server to use the default engine for the version and release number of the SAS System that you are running. (For Version 8 of the SAS System, the default engine would be
V8.) For information about other engines that may be available, see the description of the LIBNAME statement in the SAS Companion for the operating system under which your data library is stored.
Optionsfield, you may enter the following option for the library that you are defining:
Note: In order to honor this option, the SAS server through
which the library is accessed must be running under one of the following releases
of the SAS system:(footnote 1)
|Defining Libraries at Server Startup Time|
Server administrators may prefer to define SAS data libraries at server startup time rather than defining them through the SAS ODBC driver dialogs. Defining libraries at server startup time can make opening the data source faster. It also enables you to avoid hard-coding the physical names of your libraries in your SAS ODBC data-source definitions.
As explained in SAS Servers, the SAS ODBC driver uses a SAS/SHARE server (invoked by PROC SERVER) to access remote data sources. It uses a SAS ODBC server (invoked by PROC ODBCSERV) to access local data sources. To define a data library at server startup time, you precede the PROC SERVER or PROC ODBCSERV statement with a SAS LIBNAME statement. For example, you could define a library of cost-accounting data to a SAS/SHARE server as follows:
libname cost 'e:\fin\acct'; proc server id=acctserv authenticate=optional; run;
Note: Depending on the version of the SAS server, the
authenticate=optional option may not be needed.
To define this library to a SAS ODBC server, you would add only the above LIBNAME statement to the !SASROOT\CORE\SASMACRO\SASODBC.SAS file. See Startup Parameters for more information.
When a user requests access to the particular SAS ODBC data source from an ODBC client application, the server would automatically make this library available, along with any libraries that were defined via the SAS ODBC Libraries page.
For more information about the SAS LIBNAME statement, see the SAS Companion for the operating system under which your data library is stored.
|Deleting a Data Library Definition|
To delete a previously defined data library, do the following:
Librarieslist at the left of the Libraries page (Libraries Page).
|Modifying a Data Library Definition|
To change the information for a previously defined library, do the following:
Librarieslist on the Libraries page.
Top of Page
Copyright 1999 by SAS Institute Inc., Cary, NC, USA. All rights reserved.