Working with Information Map Filters

Benefits of Using Information Map Filters

Information maps support filters that enable you to subset data for efficient reporting. These filters make reporting easier by filtering out data that is not necessary for a given report and focusing on the data of interest. For example, you might create and use a filter named “Last Week” that specifies a WHERE clause for WeekDateDescRank=2 in order to report on last week's data. Or, you might create a filter named “Email Servers” to filter the data with a WHERE clause Domain='Email' in order to report on a subset of the data that relates to an email server.
As mentioned in the preceding topic, the Adapter Setup wizard automatically provides several filters for the Information Map transformations that it creates. If you create your own filter for an information map, ensure that the column with which you want to create the filter has been defined in the source table.
Note: A report can use one or more filters and these filters can be selected at reporting time. Unlike aggregation filters, these filters do not filter out any data until they are used in a report.

How to Access the Filters for an Information Map

The filters for an information map can be accessed on the Information Map Parameters tab of the Properties dialog box of the Information Map transformation. To access the filters, perform the steps that are shown in How to Access the Properties of an Information Map Transformation. Then select the Information Map Parameters tab.
Information Map Parameters
Information Map Parameters

About the Information Map Parameters Tab

As shown in the preceding display, the following information appears on the Information Map Parameters tab.
Information map name
specifies the name of the information map that the transformation creates. The name can contain no more than 60 characters. The name of information maps cannot contain any of the following characters: * ? " ' | \ / [ ] $ & > < ( ) { } : ; ` ~ % ^ @ # ! In addition, information map names cannot contain a newline, or tab character. A value is required in this field.
Information map description
specifies information about the information map. A value is optional in this field.
Use default path of the job
specifies whether you can enter a path in the Information map path.
  • If this box is checked, the Information map path points to the same folder as the job that contains the Information Map transformation. The path is grayed out in the Information map path field. This box is checked by default.
  • If this box is not checked, a path can be entered in the Information map path field.
Information map path
specifies where the transformation stores the information map that it generates. If the Use default path of the job is checked, you cannot modify the path. (The path is grayed out.) If that box is not checked, you can enter a new path.
Click Browse to select a path to the information map from the Select a Location dialog box that displays the metadata directory structure.
Information Map Filters
lists the filters for the information map in the form of a grid. Filters in an information map are criteria (rules) that subset data. You can click any of the fields of a filter (Filter Name, Filter Expression, and Filter Description) to change them. You can also add and delete filters for the information map.
#
The numbers under this symbol specify the ordinal position of the filter for the information map.
Filter Name
specifies the name of the filter. The name must be unique and can contain up to 60 characters.
Filter Expression
specifies the filter criteria (rules). The valid form for an expression of an information map filter is <<name of the table.name of the column>> valid operator and value for a numeric column or a string column.
CAUTION:
Filter expressions for information maps are case-sensitive. Filter expressions must not contain any double quotation marks.
A discrepancy in case might cause errors or unexpected results when using the information map filter with other SAS solutions. Filter expressions that contain double quotation marks might cause the Information Map transformation to fail when executed.
Here are three examples of valid expressions for information map filters:
  • <<DaySystem.DayDateDescRank>> = 1
  • <<DaySystem.DayDateDescRank>> between 1 and 7
  • <<DaySystem.Machine>> contains 'MACHINENAME'
    Note: For more information about filter expressions, see the documentation for PROC INFOMAP in the Base SAS Procedures Guide. This documentation can be found at http://support.sas.com/documentation/onlinedoc/base/index.html.
Description
displays a description of the filter. The description can contain up to 200 characters. However, short descriptions require less system memory and are often processed more efficiently by various SAS solutions.
Note: The Adapter Setup and the Add Domain Category wizards include the ranked column name and the corresponding filter value in the description for the filters that they provide. For example, if the CacheReadHitPctMinAscRank column is filtered in ascending order from one to ten (including one and ten), then the description for that filter is “CacheReadHitPctMinAscRank 1–10.” For best results, use this same convention to describe the information map filters that you create.
Column Up Arrow
reorders filters by moving a selected filter up in the list.
Column Down Arrow
reorders filters by moving a selected filter down in the list.
New
This button enables you to enter a new information map filter. When you click New, a new row appears in the filter list and you can enter the parameter values for the new filter.
Delete
This button enables you to delete an information map filter. Highlight the filter that you want to delete and click Delete.

Add a Filter to an Information Map

To add a filter to an information map, perform the following steps:
  1. Navigate to the location that contains the information map where you want to add a filter.
  2. In the appropriate Domain Categories folder of the adapter that you are working with, locate the job that contains the transformation for the information map.
  3. Double-click the job to open it on the Diagram tab of the Job Editor window.
  4. Right-click the box that represents the Information Map transformation. From the menu list, select Properties to open the Properties dialog box.
  5. Select the Information Map Parameters tab to view a grid of filters. This grid displays the name, expression, and description of filters that are already defined for the information map that this transformation creates.
  6. At the bottom of the page, click New. This action displays a new line in the grid on which you can enter a new filter. The default name of this filter is “Untitledn,” where n is the nth filter that exists for this information map.
  7. In the Filter Name column, enter the name of the filter. This name must be unique within the information map.
    Note: The Filter Name field can contain up to 60 characters. However, the information map library engine that is used by SAS Enterprise Guide to access information maps truncates filter names that are longer than 32 characters. To avoid the potential for truncation when using this information map with other SAS solutions, specify a filter name that does not exceed 32 characters in length.
  8. In the Filter Expression column, enter the expression that specifies the filter criteria. The valid form for an expression of an information map filter is <<name of the table.name of the column>> valid operator and value for a numeric column or a string column. Here are three examples of valid expressions for information map filters:
    • <<DaySystem.DayDateDescRank>> = 1
    • <<DaySystem.DayDateDescRank>> between 1 and 7
    • <<DaySystem.Machine>> contains 'MACHINENAME'
    If you enter an invalid expression, the following message will appear in the log when the job is run: Error: Failed to insert filter <name-of-filter>.
    CAUTION:
    Filter expressions for information maps are case-sensitive. Filter expressions must not contain any double quotation marks.
    A discrepancy in case might cause errors or unexpected results when using the information map filter with other SAS solutions. Filter expressions that contain double quotation marks might cause the Information Map transformation to fail when executed.
    Note: SAS Enterprise Guide honors both measures and categories for information map filters. In SAS Enterprise Guide, you can open the information map that is generated from this transformation and you can select the filters that you have created.
  9. In the Description column, enter a brief description of the filter. The description can contain up to 200 characters. However, short descriptions require less system memory and are often processed more efficiently by various SAS solutions. For best results, minimize the number of characters in the description while maintaining meaning and clarity.
    Note: The Adapter Setup wizard includes the ranked column name and the corresponding filter value in the description for the filters that it provides. For example, if the CacheReadHitPctMinAscRank column is filtered in ascending order from one to ten (including one and ten), then the description for that filter is “CacheReadHitPctMinAscRank 1–10.” For best results, use this same convention to describe the information map filters that you create.
  10. Click OK to save. The new filters that you create are available in the information map only after the corresponding job runs.

Modify a Filter on an Information Map

To modify a filter on an information map, perform the following steps:
  1. Navigate to the location that contains the information map where you want to modify a filter.
  2. In the appropriate Domain Categories folder of the adapter that you are working with, locate the job that contains the transformation for the information map.
  3. Double-click the job to open it on the Diagram tab of the Job Editor window.
  4. Right-click the box that represents the Information Map transformation.
  5. From the menu list, select Properties to open the Properties dialog box.
  6. Select the Information Map Parameters tab to view a grid of filters. The grid displays the name, expression, and description of filters that are defined for the information map that this transformation creates.
  7. In the Information Map Filters panel of the tab, highlight the field of the filter that you want to change and enter the revised value. In addition, you can click New to add a filter to the grid or Delete to delete a highlighted filter from the grid.
  8. Click OK to save the Information Map transformation with its revised filter. The filter is revised only after the corresponding job runs.

Delete a Filter from an Information Map

Deleting an information map filter can create unexpected results in reporting if your reports use the filter that was deleted. For example, if a report used an information map filter that was deleted, then the next time the report is run, it can experience errors or produce unexpected results. Do not delete an information map filter unless you are certain that this action will not negatively affect your reporting needs.
To delete a filter from an information map, perform the following steps:
  1. Navigate to the location that contains the information map where you want to delete a filter.
  2. In the appropriate Domain Categories folder of the adapter that you are working with, locate the job that contains the transformation for the information map.
  3. Double-click the job to open it on the Diagram tab of the Job Editor window.
  4. Right-click the box that represents the Information Map transformation.
  5. From the menu list, select Properties to open the Properties dialog box.
  6. Select the Information Map Parameters tab to view a grid of filters. The grid displays the name, expression, and description of filters that are defined for the information map that this transformation creates.
  7. Right-click the filter that you want to delete.
  8. From the menu list, select Delete.
  9. Click OK to save. The filter is deleted in the information map only after the corresponding job runs.
Note: Filter changes are not applied immediately. They are applied the next time the job runs.