LIBNAME Statement

Associates a SAS libref with information maps.

Syntax

LIBNAME libref INFOMAPS MAPPATH="location" <options>

Summary of Optional Arguments

Options for Connecting to the SAS Metadata Server
specifies an authentication domain in the metadata server that is associated with the user ID and password.
specifies whether the user ID and password specified in the METAUSER= and METAPASS= system options are retrieved and used to connect to the metadata server when the METAUSER= and METAPASS= options for the LIBNAME statement are omitted.
specifies the password that corresponds to the user ID that connects to the metadata server.
specifies the TCP port that the metadata server is listening to for connections.
specifies the network IP (Internet Protocol) address of the computer that hosts the metadata server.
specifies the user ID to connect to the metadata server.
specifies whether Integrated Windows Authentication is used.
Other Options for the Information Maps Engine
specifies whether detailed data or aggregated data is retrieved from the data source.
specifies the length of the SAS character column when a data item defined with an expression is encountered.
specifies how information map names are handled.
specifies the number of rows to hold in memory for input into SAS.
specifies whether a spool file is created.

Required Arguments

libref
is a SAS name that refers to the metadata server library to be accessed. A libref cannot exceed eight characters. For additional rules for SAS names, refer to SAS Language Reference: Concepts.
INFOMAPS
is the engine name for the SAS Information Maps LIBNAME engine.
MAPPATH="location"
specifies the path to the location of the information maps within the metadata server. The path is hierarchical with the slash (/) as the separator character. For example, mappath="/Users/myUserID/My Folder".
Alias:PATH=

Options for Connecting to the SAS Metadata Server

The following LIBNAME statement options establish a connection to the metadata server:
DOMAIN="authentication-domain"
specifies an authentication domain in the metadata server that is associated with the user ID and password. If you do not specify an authentication domain, then the user ID and password are associated with the DefaultAuth authentication domain. For information about authentication, see "Understanding Authentication in the SAS Intelligence Platform" in SAS Intelligence Platform: Security Administration Guide.
Alias:AUTHDOMAIN=
Default:DefaultAuth
METACREDENTIALS=YES | NO
specifies whether the user ID and password specified in the METAUSER= and METAPASS= system options are retrieved and used to connect to the metadata server when the METAUSER= and METAPASS= options for the LIBNAME statement are omitted. By default, or when METACREDENTIALS=YES is specified, the system option values are used if they are available when the LIBNAME statement does not provide the corresponding options. Specify METACREDENTIALS=NO to prevent the Information Maps engine from using the system option values.
A typical situation in which you would specify METACREDENTIALS=NO is when the code containing the LIBNAME statement is being executed on a workspace server or stored process server. In such cases, the METAUSER= and METAPASS= system options contain a one-time user ID and password that have already been used by the server. A new one-time password must be generated in this situation. Specifying METACREDENTIALS=NO enables a connection to be established under the identity of the client user using a new one-time password.
Default:YES
METAPASS="password"
specifies the password that corresponds to the user ID that connects to the metadata server. If your metadata server supports single sign-on, you can omit the METAPASS= and METAUSER= options and connect through a trusted peer connection or through Integrated Windows Authentication. For more information, see the SAS Intelligence Platform: Security Administration Guide.
You can use the METAPASS= system option to specify a default password for connecting to the metadata server for the SAS session. For information about the METAPASS= system option, see SAS Language Interfaces to Metadata.
Specifying a plain-text password can compromise security. You can use the PWENCODE procedure to encode the password value. For information about the PWENCODE procedure, see Base SAS Procedures Guide.
Aliases:PASSWORD=

PW=

Note:If the password is not encoded or does not contain a blank space (or spaces), then enclosing the identifier in quotation marks is optional.
Examples:
metapass="My Password"

metapass=MyPassword

METAPORT=port-number
specifies the TCP port that the metadata server is listening to for connections. If this option is not specified, the value is obtained from the METAPORT= system option. For information about the METAPORT= system option, see SAS Language Interfaces to Metadata.
Alias:PORT=
Example:
metaport=8561
METASERVER="address"
specifies the network IP (Internet Protocol) address of the computer that hosts the metadata server. If this option is not specified, the value is obtained from the METASERVER= system option. For information about the METASERVER= system option, see SAS Language Interfaces to Metadata.
Aliases:SERVER=

HOST=

IPADDR=

Note:Enclosing the identifier in quotation marks is optional.
Example:
metaserver="myip.mycompany.com"
METAUSER="user-ID"
specifies the user ID to connect to the metadata server. You can use the METAUSER= system option to specify a default user ID for connecting to the metadata server for the SAS session. For information about the METAUSER= system option, see SAS Language Interfaces to Metadata.
If your metadata server supports single sign-on, you can omit the METAUSER= and METAPASS= options and connect through a trusted peer connection or through Integrated Windows Authentication. For more information, see the SAS Intelligence Platform: Security Administration Guide.
Aliases:USER=

USERID=

ID=

Restrictions:In the metadata server, you must have at least one login definition that corresponds to the user ID that you specify here. For information about login definitions, see the User Manager Help for logins in the SAS Management Console.

If your metadata server runs in a Windows environment, then you must fully qualify the user ID by using the domain or machine name that you specified when your login object was created in a SAS Metadata Server. For example, metauser="domain-name\user-ID".

Note:If the user ID does not contain a blank space (or spaces) or a backslash character, enclosing the identifier in quotation mark is optional.
Examples:
metauser="My UserID"

metauser=myUserID

SSPI=YES | NO
specifies whether Integrated Windows Authentication is used. Integrated Windows Authentication is a mechanism for a Windows client and server to exchange credentials without the user having to explicitly specify them. For more information, see "Integrated Windows Authentication" in the SAS Intelligence Platform: Security Administration Guide.
Default:NO

Other Options for the Information Maps Engine

The following LIBNAME statement options for the Information Maps engine are global options that exist for the lifetime of the libref:
AGGREGATE=YES | NO
specifies whether detailed data or aggregated data is retrieved from the data source.
YES specifies that aggregated data is retrieved.
NO specifies that detailed data is retrieved.
By default, or when you specify AGGREGATE=NO, aggregate data items in the information map are not accessible through the Information Maps engine. If an information map contains such data items, then a warning is displayed in the SAS log indicating how many data items are not accessible. Specify AGGREGATE=YES to retrieve aggregated data.
When you specify AGGREGATE=YES and use the CONTENTS procedure to view the contents of an information map, a column named Default Aggregation appears in the procedure output showing the default aggregation function that is assigned to the variable. If the original variable was character type, it is changed to numeric type due to applying the aggregation function. For example, a default aggregation function of COUNT on a character variable containing names produces a numeric variable that contains the number of names. A line in the heading of the CONTENTS procedure output shows the number of aggregate variables, if any.
Default:NO
Note:The Information Maps engine also supports an AGGREGATE= data set option that you can use to change this option setting during a DATA step when the Information Maps engine is used. The changed value is in effect only during the execution of the DATA step. Once the DATA step is completed, the value reverts to the setting specified when the libref was created. For more information, see AGGREGATE= Data Set Option.
EXPCOLUMNLEN=integer
specifies the length of the SAS character column when a data item defined with an expression is encountered.
Default:32
Note:The Information Maps engine also supports an EXPCOLUMNLEN= data set option that you can use to change this option setting during a DATA step when the Information Maps engine is used. The changed value is in effect only during the execution of the DATA step. Once the DATA step is completed, the value reverts to the setting specified when the libref was created. For more information, see EXPCOLUMNLEN= Data Set Option.
PRESERVE_MAP_NAMES=YES | NO
specifies how information map names are handled.
YES
specifies that information map names are read with special characters. The exact, case-sensitive spelling of the name is preserved.
Note: To access information maps with special characters or blank spaces, you must use SAS name literals. For more information about SAS name literals, see "Rules for Words and Names in the SAS Language" and "Avoiding Errors When Using Name Literals" in SAS Language Reference: Concepts.
NO
specifies that information map names are derived from SAS member names by using SAS member-name normalization. When you use SAS to retrieve a list of information map names (for example, in the SAS Explorer window), the information maps whose names do not conform to the SAS member-name normalization rules do not appear in the output.
The DATASETS procedure reports the number of information maps that cannot be displayed because their names cannot be normalized, as shown in the following example:
NOTE: Due to the PRESERVE_MAP_NAMES=NO LIBNAME option setting, 12 information map(s) have not been displayed.
This note is not displayed when you view information maps in the SAS Explorer window.
The SAS Explorer window displays information map names in capitalized form when PRESERVE_MAP_NAMES=NO. These information map names follow the SAS member-name normalization rules and might not represent the actual case of the information map name.
Default:YES
READBUFF=integer
specifies the number of rows to hold in memory for input into SAS. Choosing the optimum value for the READBUFF= option requires a detailed knowledge of the data that is returned from the information map and of the environment in which the SAS session runs. Buffering data reads can decrease network activities and increase performance. However, higher values for READBUFF= use more memory. In addition, if too many rows are selected at once, then the rows that are returned to the SAS application might be out of date. For example, if someone modifies the rows after they are read, then you do not see the changes.
Alias:BUFFSIZE=
Default:1000
Restriction:The specified value must be a positive integer.
Note:The Information Maps engine also supports a READBUFF= data set option that you can use adjust the buffer size during a DATA step when using the Information Maps engine. This changed value is in effect only during the execution of the DATA step. Once the DATA step is completed, the value reverts to the setting specified when the libref was created. For more information, see READBUFF= Data Set Option.
SPOOL=YES | NO
specifies whether a spool file is created.
YES
specifies that SAS creates a spool file into which it writes the rows of data that are read for the first time. For subsequent passes through the data, rows are read from the spool file, rather than being reread from the original data source(s). This guarantees that each pass through the data processes the same information.
NO
specifies that the required rows for all passes through the data are read from the original data source(s). No spool file is written. There is no guarantee that each pass through the data processes the same information.
Default:YES