Understanding How the Information Maps Engine Works

An engine is a component of SAS software that reads from or writes to a file. (The Information Maps engine is read-only.) Each engine enables SAS to access files that are in a particular format. There are several types of SAS engines.
The Information Maps engine works like other SAS data access engines. That is, you execute a LIBNAME statement to assign a libref and to specify an engine. You then use that libref throughout the SAS session where a libref is valid. However, instead of the libref being associated with the physical location of a SAS library, the libref is associated with a set of information maps. The information maps contain metadata that the engine uses to provide data access to users.
Note: The Information Maps engine honors the permission settings defined in the metadata for the information map and its data sources. A user is not allowed to access data via the Information Maps engine if the user's Read permission for the information map or its data sources in the metadata server is DENY.
The following example shows a LIBNAME statement for the Information Maps engine and the output that you see when you execute the statement:
 libname mymaps infomaps metauser=myUserID
                         metapass=myPassword
                         metaserver="myserver.mycompany.com"
                         metaport=8561
                         mappath="/Users/myUserID/My Folder";
Log for the LIBNAME Statement
 1  libname mymaps infomaps metauser=myUserID
 2                          metapass=XXXXXXXXXX
 3                          metaserver="myserver.mycompany.com"
 4                          metaport=8561
 5                          mappath="/Users/myUserID/My Folder";

 NOTE: Libref MYMAPS was successfully assigned as follows:
       Engine:        INFOMAPS
       Physical Name: /Users/myUserID/My Folder
The DATASETS procedure can be used to display a list of available information maps.
Note: The list of available information maps will include only those that are supported by the engine. For example, there might be OLAP-based information maps available in the MAPPATH location. However, these information maps are not supported by the Information Maps engine, so they will not be displayed by the DATASETS procedure.
The CONTENTS procedure can be used to view the data items and filters in an information map. The PRINT procedure can be used to print all of the data that the information map contains. If the map contains filters, they can be used to restrict the returned data. Here is an example:
/* Use the Information Maps engine to retrieve the data. */
libname mymaps infomaps metauser=myUserID
                        metapass=myPassword
                        metaserver="myserver.mycompany.com"
                        metaport=8561
                        mappath="/Users/myUserID/My Folder";

 /* Display a list of available information maps. */
 proc datasets lib=mymaps;
 run;
 quit;

 /* Allow mixed-case letters and blank spaces in information map names. */
 option validvarname=any;

 /* View the data items, including any filters, in the information map. */
 proc contents data=mymaps.'Employee Statistics Sample'n;
 run;

 /* Print 5 observations from the data that the information map references. */
 proc print data=mymaps.'Employee Statistics Sample'n (obs=5
    filter=('Cary Employees'n));
 run;
Log for the Example Program
 1  /* Run the Information Maps engine to retrieve the data. */
 2  libname mymaps infomaps metauser=myUserID
 3                          metapass=XXXXXXXXXX
 4                          metaserver="myserver.mycompany.com"
 5                          metaport=8561
 6                          mappath="/Users/myUserID/My Folder";

 NOTE: Libref MYMAPS was successfully assigned as follows:
       Engine:        INFOMAPS
       Physical Name: /Users/myUserID/My Folder
 7
 8  /* Display a list of available information maps. */
 9  proc datasets lib=mymaps;
                                             Directory
                              Libref         MYMAPS
                             Engine         INFOMAPS
                             Physical Name  /Users/myUserID/My Folder

                                                              Member
                               #  Name                        Type

                               1  Employee Statistics Sample  DATA
 10  run;
 11  quit;

 NOTE: PROCEDURE DATASETS used (Total process time):
       real time           0.06 seconds
       cpu time            0.00 seconds

 12
 13  /* Allow mixed-case letters and blank spaces in information map names. */
 14  option validvarname=any;
 15
 16  /* View the data items, including any filters, in the information map. */
 17  proc contents data=mymaps.'Employee Statistics Sample'n;
 18  run;

 NOTE: PROCEDURE CONTENTS used (Total process time):
       real time           0.09 seconds
       cpu time            0.00 seconds

 19
 20  /* Print 5 observations from the data that the information map references. */
 21  proc print data=mymaps.'Employee Statistics Sample'n (obs=5
 22     filter=('Cary Employees'n));
 23  run;

 NOTE: There were 5 observations read from the data set MYMAPS.'Employee Statistics Sample'n.
 NOTE: PROCEDURE PRINT used (Total process time):
       real time           0.23 seconds
       cpu time            0.11 seconds
Output from the CONTENTS and PRINT Procedures
                                           The SAS System

                                       The CONTENTS Procedure

        Data Set Name        MYMAPS.'Employee Statistics Sample'n    Observations          .
        Member Type          DATA                                    Variables             11
        Engine               INFOMAPS                                Indexes               0
        Created              .                                       Observation Length    0
        Last Modified        .                                       Deleted Observations  0
        Protection                                                   Compressed            NO
        Data Set Type                                                Sorted                NO
        Label                                                        Filters               1
        Data Representation  Default
        Encoding             Default


                             Alphabetic List of Variables and Attributes
   # Variable            Type Len Format     Label
   4 Deptcode            Char   3            Physical column EMPINFO.DEPTCODE
  10 Hire Date           Num    8 DATE9.     Hire date
   2 Identification      Num    8 SSN11.     Identification Number
     Number
   3 Jobcode             Char   8            Physical column EMPINFO.JOBCODE
   5 Location            Char   8            Physical column EMPINFO.LOCATION
   1 Name                Char  32 $32.       NAME
  11 Number of Years     Num    8 COMMA6.    The number of years that the employee
     Employed                                has been employed by the company.
   7 Salary2             Num    8 DOLLAR12.2 Salary
   8 Salary3             Num    8 DOLLAR12.2 Salary
   9 Salary4             Num    8 DOLLAR12.2 Salary
   6 Salary_2            Num    8 DOLLAR12.2 Salary

                                           Information Maps
             FilterName         FilterType  FilterDesc

             Cary Employees     Unp         Employees who work in Cary, North Carolina.

                                                Identification
      Obs   Name                                    Number        Jobcode    Deptcode    Location

        1   Bryan, Lynne C.                      000-00-0381      VID002       VID         Cary
        2   Fissel, Ronald T.                    000-00-0739      QA0005       QA0         Cary
        3   White, Frank P.                      000-00-1575      DPD003       FAC         Cary
        4   Winfree, Ambrose Y.                  000-00-1579      CCD001       CCD         Cary
        5   Blue, Kenneth N.                     000-00-1637      MIS004       QA0         Cary

                                                                                    Number of
                                                                                      Years
      Obs       Salary_2        Salary2        Salary3        Salary4   Hire Date   Employed
        1    $183,000.00    $183,000.00    $183,000.00    $183,000.00   08APR1984        25
        2     $85,000.00     $85,000.00     $85,000.00     $85,000.00   02FEB1985        24
        3     $69,000.00     $69,000.00     $69,000.00     $69,000.00   01JUN1984        24
        4    $100,000.00    $100,000.00    $100,000.00    $100,000.00   14JUN1989        19
        5     $18,000.00     $18,000.00     $18,000.00     $18,000.00   12NOV1991        17

NOTE: There were 277 observations read from the data set SAMPDATA.EMPINFO.LOCATION='Cary    ';