When you create an entity business rule (EBR), you can include a Filter By, Group By, and Aggregate By option. These options define criteria that refine your profiling results. Use the advanced options to help track data quality compliance by highlighting errors in your data.
This topic describes how to use each option, and includes guidelines and examples.
Guidelines
Note the following when working with EBR options:
- You define the three EBR advanced options by adding expression, attribute, and function parameters. Use multiple values to further refine the results.
- Any filter, group, or aggregate expression added to a rule remains with the rule when it is copied to another entity, promoted to the Entity Business Rules Library, and exported from the Library. When a library rule is re-used, the associated rule inherits the option along with the rule's expression.
- Each option generates information about errors that occurred during analysis, such as the number of rows that caused the error, the value of the first error row, and the corresponding error message. For more information, see Business Rules Analysis Details.
- EBR options are not supported for dynamic entities. When you create an EBR for a dynamic entity, the options are grayed out.
- The Group By option has no maximum limit.
Using EBR Options
You can enable these options in the Expression Builder when you first build a rule or when you edit an existing rule. Combine options when necessary to further enhance your results.
Filter By
Runs the business rule test against a specified set of rows and values.
- Show Examples
-
Example 1
You need to determine which bank accounts have a balance of more than 0, although a 0 balance is acceptable for a Z type of account. Add a Filter By option so the rule runs against accounts that are not equal to type Z so these acceptable 0-balance accounts are excluded from the results. Any rows that fail the rule analysis will have a 0 balance for account types where a 0 balance is not acceptable.
- See the rule expression and Filter By option in the Expression Builder:
-
Example 2
You need to verify that car, house, and accident insurance policies have a payment period of 1 month. Add a Filter By option to direct the business rule expression to run against only the three policy types. Any rows that fail the rule analysis will have a payment period value other than 1.
- See the rule expression and Filter By option in the Expression Builder:
-
Group By
Splits the results of a business rule expression into multiple categories based on parameters you define. You then drill down from the analyzed rule to view and compare the passing, failing, and total number of rows in each group.
Right-click the entity, select Business Rules > Drill down to Entity Business Rules, and then right-click the business rule and select Drill down to Group to display each group.
Note about ulimits and nofiles
When using the Groups By option with a very large number of rules, say for example 300 rules, for a single entity, you will be opening 300 files at once (one for each group). However, if your UNIX ulimits only allows you fewer file handles than 300, you will receive an error.
In order to avoid this situation, it is recommended that you set the nofiles value to unlimited. Alternatively, assess the number of rules with groups you need to create and double the number for ulimits.
- Show Examples
-
Example 1
You need to compare all 0 account balances categorized by product type. After rule analysis, drill down to a List View of grouped product type values and compare results.
- See the rule expression and Group By option in the Expression Builder:
-
Example 2
You need to compare insurance policies categorized by policy type where certain policy data is missing. After rule analysis, drill down to a List View of grouped product type values with the data missing and compare results.
- See the rule expression and Group By option in the Expression Builder:
-
Aggregate By
Totals numeric values for business rule passing and failing results. You aggregate results using one of five mathematical operators: sum, average, maximum, minimum, and count. When used with the Filter By or Group By options, aggregation is run on the filtered or grouped rows. Aggregated group results show the aggregate value results over passing and failing rows for each group.
- Show Examples
-
Example 1
Every insurance policy must include a payment period. You need to show the total count and sum across values for the attribute Sum Assured for policies with no payment period assigned. After rule analysis, you can see the total aggregate value across passing and failing rows. You can drill down to see which rows passed or failed business rule compliance.
- See the rule expression and Aggregate By option in the Expression Builder:
-
Example 2
The same as Use Case 1, but you now must categorize by Policy Type. After rule analysis you can drill down to aggregate value results for passing and failing row results for each group.
- See the rule with the Group By option added in the Expression Builder:
-
The following List View shows the drill-down to the rule results by group. The Value column shows the Sum Assured attribute values grouped by Policy Type. From this view, you can drill down to all failing rows for a specific group (right-click any group and select Drill down to failing rows).