Applying behaviors to logical models
Behaviors enable you to set prefer or deny relationships between measure groups and other groups. You can also use behaviors to enforce value selection in Insight Advisor.
You may have groups that either should be always used together in analysis or never used together in analysis. You also maybe have field values that you would prefer always been included as selected when fields from a group are being used by Insight Advisor. Behaviors enable you to set these preferences on a group by group basis. Logical model behaviors are created and managed in Behaviors.
The following behaviors are available in logical models:
- Required selections
- Prefer relationship
- Deny relationship
You can edit or delete behaviors by clicking and selecting Edit or Delete.
Required selection behavior enables you to specify field values that must be included when using fields from a group. A behavior can include multiple required selections.
For example, you may have fields for Country, Population, and Year. When generating recommendations in Insight Advisor, you might get charts that use Country and Population, but include the sum of data for all years in the charts. You can use required selection behavior to limit insights results to instead use the current year instead when generating insights for Population or Country.
Prefer relationship behavior guides Insight Advisor into selecting groups that should be used more often together when generating insights. When you specify a prefer relationship, Insight Advisor uses the preferred group when generating results. Prefer relationships are useful when there might be ambiguity .
Prefer relationships does not prevent a group from being used with other groups. It only selects the preferred group when all group choices are equal in the analysis. In analysis where other groups are more appropriate, the non-preferred groups may be used instead.
For example, there are four groups:
- Sales Person
Sales has a preferred relationship with Customer. For a breakdown analysis with Sales, Customer is selected over the other groups as it is preferred. For a trend analysis for Sales, Product might be used in the analysis instead.
Deny relationship behavior prevents Insight Advisor from using the selected groups together when generating insights. This is useful when some groups in the same package may not be usefully to use together in analysis. Deny relationships can also be used to block groups from being used together that might impact app performance. With star schema data models, there may be groups that have one-to-many and many-to-one relationships that complicate analysis. Deny relationships can prevent association between these groups.
Deny relationships are overruled when a user specifically requests insights from the groups that have a deny relationship. For example, Sales and Supplier have a deny relationship. If someone queries 'show me sales', no analysis will be generated that contains Sales and Supplier. If someone queries 'show me sales by supplier', results including Sales and Supplier are generated.
Do the following:
- Click Create behavior.
- Under Applies to, select a group.
- Select a behavior type
- Do one of the following:
- If configuring a Prefer relationship or a Deny relationship, select the groups to which to apply that relationship.
If configuring a Required selection, select if this is a single value. From Require for, select the fields and their required values.
You can add additional required selections by clicking Add another.
- Click Create.