METALIB Procedure

OMR Statement

Specifies the data source and connection parameters for the SAS Metadata Server.

Syntax

OMR <=> (library-identifier <server-connection-arguments>);

Required Argument

library-identifier
specifies a SASLibrary object, which defines a SAS library. This SAS library contains the tables whose metadata is updated. The SASLibrary object can be specified using any of the following forms:
LIBID=<">identifier<">
specifies the 8-character metadata identifier of the SASLibrary object that represents the library. The 8-character metadata identifier is the second half of the 17-character identifier. For more information, see Metadata Object Identifiers and URIs.
LIBRARY=<">name<">
specifies the value in the SASLibrary object's Name= attribute.
LIBURI="URI-format"
specifies a URI, which is a standard from SAS Open Metadata Architecture. For more information, see Metadata Object Identifiers and URIs. The following URI formats are supported:
LIBURI="identifier.identifier"
specifies the full 17-character metadata identifier, which references both the repository and the object. This syntax is equivalent to specifying both LIBID= and REPID=. An example is liburi="A58LN5R2.A9000001".
LIBURI="SASLibrary/identifier.identifier"
specifies the SASLibrary object type, followed by the full 17-character metadata identifier. This syntax is equivalent to specifying both LIBID= and REPID=. An example is liburi="SASLibrary/A58LN5R2.A9000001".
LIBURI="SASLibrary?@attribute='value'"
specifies the SASLibrary object type, followed by a search string. Examples are liburi="SASLibrary?@libref='mylib'" and liburi="SASLibrary?@engine='base'".
Requirements:You must enclose the LIBURI= value in quotation marks.

The URI must resolve to a single metadata object. When using an attribute qualifier like @engine=’base’, if you have more than one Base library defined in metadata, PROC METALIB returns WARNING: Multiple metadata objects found.

Note:SAS Data Integration Studio can process work tables that exist temporarily in the Work library. The metadata type is WorkTable. Usually, work tables are not assigned to a library and have no library metadata, but they do have table and column metadata. A work table that results from a generated transformation can be dynamic in nature. In other words, its structure might be modified by the transformation. PROC METALIB can update the metadata to match the work table. If there is no library assignment, submit a blank library specification, and identify the work table with the SELECT statement. Here is an example with a blank library specification: proc metalib; omr (libid="" repid="A5O7HLNB"); select ("A5O7HLNB.A9000001"); run;
Tip:In SAS Management Console, avoid the Pre-assigned Library template. When you pre-assign a library, choose the resource template that is specific to the type of data source library that you are creating, and select the This library is pre-assigned check box. The Pre-assigned Library template is intended for certain system libraries only, and it does not work for other libraries. In addition, for PROC METALIB, you must submit the library pre-assignment in the current SAS session. You can store the LIBNAME statement in an autoexec file, or you can submit the LIBNAME statement in your SAS session before you submit the procedure.

Server Connection Arguments

The server connection arguments establish communication with the metadata server. If you omit these arguments, then the values of the system options are used, or the values can be obtained interactively. For more information, see Connection Options .

PASSWORD="password"
is the password for the authorized user ID on the metadata server. If you do not specify PASSWORD=, the value of the METAPASS= system option is used. For more information, see METAPASS= System Option. The maximum length is 256 characters.
Alias:METAPASS= or PW=
PORT="number"
is the TCP port that the metadata server listens to for connections. This port number was used to start the metadata server. If you do not specify PORT=, the value of the METAPORT= system option is used. For more information, see METAPORT= System Option. The range of allowed port numbers is 1 to 65535. The metadata server is configured with a default port number of 8561.
Alias:METAPORT=
REPID=<">identifier<"> | REPNAME=<">name<">
specifies the repository that contains the SASLibrary object. If you specify both REPID= and REPNAME=, REPID= takes precedence over REPNAME=. If you do not specify REPID= or REPNAME=, the value of the METAREPOSITORY= system option is used. For more information, see METAREPOSITORY= System Option. The default for the METAREPOSITORY= system option is FOUNDATION.
REPID=<">identifier<">
specifies an 8-character identifier. This identifier is the first half of the SASLibrary object's 17-character identifier, and is the second half of the repository's identifier. For more information, see Metadata Object Identifiers and URIs.
REPNAME=<">name<">
specifies the value in the repository's Name= attribute. The maximum length is 256 characters.
Alias:METAREPOSITORY=
SERVER="host-name"
is the host name or network IP address of the computer that hosts the metadata server. The value LOCALHOST can be used if the SAS session is connecting to a server on the same computer. If you do not specify SERVER=, the value of the METASERVER= system option is used. For more information, see METASERVER= System Option. The maximum length is 256 characters.
Alias:HOST= or IPADDR= or METASERVER=
USER="authorized-user-ID"
is an authorized user ID on the metadata server. An authorized user ID has ReadMetadata and WriteMetadata permission to the specified SASLibrary. It has WriteMemberMetadata permission to the SAS folders that are affected by the update. SAS folders that can be affected by the update include the library's folder and the table's folder, if the table is in a different folder from the library. For more information, see SAS Intelligence Platform: Security Administration Guide. If you do not specify USER=, the value of the METAUSER= system option is used. For more information, see METAUSER= System Option. The maximum length is 256 characters.
Alias:ID= or METAUSER= or USERID=