Defining Conditions 

Prerequisites

You have executed a query. You want to define one or more conditions for this query, and have chosen Change query (global definition) from the BEx toolbar.

Procedure

Defining Conditions

  1. Choose New Condition. (This menu path is under the pushbutton with the arrow pointing downwards on the right next to the Condition symbol). You get to the dialog box Define conditions.
  1. Specify a name for the condition in the Description field.

If you want to just define the condition, and do not want to execute it actively in the query, remove the check from the active field that is there by default.

  1. You now have the following options:

The condition row is Sales Top 5.

If the characteristic Customer is the only one in the query, the top 5 customers as far as sales are concerned are displayed because of the condition. If the characteristic Product is the only one in the drilldown, the top 5 products as far as sales are concerned are displayed. What’s more, if Customer and Product are in the drilldown, the top 5 customers and the top 5 products, as far as sales are concerned, are displayed, as well as all 25 combinations of the two.

    1. If you only want to evaluate the condition if it is in the drilldown, select it with a check.
    2. The condition row is Sales Top 5.

      You have selected Customer as the only characteristic. The condition is only evaluated if Customer is in the drilldown. Only the top 5 customers with their sales are displayed.

    3. Select several characteristics with a check, if you want to evaluate the condition for characteristic combinations.

The condition row is Sales Top 5.

You have selected the characteristics Customer and Product with a check. The condition is only evaluated if Customer and Product are in the drilldown at the same time. The option All characteristics independent in drilldown, displays the top 5 customer-product combinations with sales, so only 5 rows instead of 25 (see above).

If you have defined several conditions for a query, there may be clashes between the conditions that refer to the same characteristics. In this case, certain rules of priority apply. It is generally the most specific condition that applies when there are clashes.

One condition defines the top 5 sales for the characteristic Customer, a second condition defines the bottom 3 sales in the customer-product combination.

If only characteristic Customer is in the drilldown, only the first condition applies. So, only the condition top 5 sales is used for the characteristic Customer.

If Customer and Product are in the drilldown at the same time, you can use both conditions according to your definition. In this case, the second condition applies, since it is the most specific because of its reference to the characteristic combination.

  1. In the field Present all values that fulfill at least one of the following conditions, enter one or more condition rows into the list. See Conditions/Exceptions: Inserting, changing, deleting rows

A condition row is always derived from the determination of an element for every structure used in the query (usually one or two structures), an operator and a value that matches the operator.

You can choose from the following operators for threshold conditions:

These operators demand a floating point number as a value. For the operators is in interval and is not in interval, you must enter a value area; a lower and an upper threshold value.

You can choose from the following operators for ranked list functions:

For Top/Bottom N, you must enter a whole, positive number as the value. For Top/Bottom percent, enter a number between 0 and 100. For Top/Bottom sum, you can also enter a floating point number (for example, 15.7).

The entry format depends on the country setting of the operative system.

To make it easier to enter larger numbers, there is the following entry convention:

A quotation mark behind the number means it is multiplied by one thousand, two quotation marks means a multiplication by one million and three quotation marks means a multiplication by one billion, for example 1.5" = 1.5 Mio = 1.500.000.

A group of condition rows is logically linked with OR. This means that at least one of the condition rows has to be filled for the entire condition to be filled for one characteristic value.

  1. Choose OK. This takes you back to the query definition.
  1. Choose Save.

Changing Conditions

  1. Choose Change condition. (This menu path is under the pushbutton with the arrow pointing downwards on the right next to the Condition symbol). You get to the selection window for the conditions that have already been defined.
  2. Choose the condition you want to use, and then choose OK. You get to the dialog box Defining conditions, where you make the changes.
  3. In the query definition, choose Save.

Deleting Conditions

  1. Choose Condition. You get to the selection window for the conditions that have already been defined.
  2. Choose the condition you want, and then choose Delete.
  3. In the query definition, choose Save.

Result

You have defined or deleted a condition for a query. Execute the query. Only those objects are displayed which fulfill the defined conditions.

Display the descriptions of the conditions in the query view, and activate/deactivate them with a double-click, or the right mouse button. Choose Layout ® Display conditions.

See also:

Using Conditions