Siebel Analytics Server Administration Guide > Administration Tool Utilities and Expression Builder >

Expression Builder


You can use the Expression Builder dialog boxes in the Administration Tool to create constraints, aggregations, and other definitions within a repository. The expressions you create with the expression builder are similar to expressions created with SQL. Except where noted, you can use all expressions constructed with the expression builder in SQL queries against the Siebel Analytics Server.

For information about using SQL with the expression builder, see SQL Syntax and Semantics. For information about the SQL functions supported by the Siebel Analytics Server, see SQL Reference.

This section includes the following topics:

About the Expression Builder Dialog Boxes

You can access the expression builder from the following dialog boxes:

Figure 14 shows an example of an expression builder. The edit pane at the top of the dialog box allows you to edit the current expression. In the lower half of the dialog box, the left pane is the Selection pane. It displays the folders that are appropriate for the dialog box from which you accessed the expression builder. The middle pane is the Categories pane. It displays the available categories for the folder you select in the Selection pane. The right pane is the Building Blocks pane. It displays the individual building blocks for the category you select in the Category pane. The toolbar in the middle contains commonly used expression building blocks.

Figure 14.  Example Expression Builder

Click for full size image

Expression Builder Toolbar

The toolbar is located in the middle portion of the expression builder. Table 14 describes each icon and its function in an expression.

Table 14.  Expression Builder Toolbar
Operator
Description
+
Plus sign for addition.
-
Minus sign for subtraction.
*
Multiply sign for multiplication.
/
Divide by sign for division.
||
Character string concatenation.
(
Open parenthesis.
)
Close parenthesis.
>
Greater than sign, indicating values higher than the comparison.
<
Less than sign, indicating values lower than the comparison.
=
Equal sign, indicating the same value.
<=
Less than or equal to sign, indicating values the same or lower than the comparison.
>=
Greater than or equal to sign, indicating values the same or higher than the comparison.
<>
Not equal to, indicating values higher or lower, but not the same.
AND
AND connective, indicating intersection with one or more conditions to form a compound condition.
OR
OR connective, indicating the union with one or more conditions to form a compound condition.
NOT
NOT connective, indicating a condition is not met.
,
Comma, used to separate elements in a list.

Folders in the Selection Pane

The folders that appear in the Selection pane vary based on the dialog box from which you accessed the expression builder. This section describes the folders that may appear.

Aggregate Content

The Aggregate Content folder contains the available aggregate functions. Aggregate sources must use one of the functions listed here to specify the level of their content.

Dimensions

The Dimensions folder contains the dimension configured in the business model. If no dimension exists in a business model, or if the dimension folder is not pertinent to a particular expression builder, the Dimension folder is not displayed.

When you select the Dimensions folder, each configured dimension displays in the middle pane, and each level for the selected dimension displays in the right pane.

Logical Tables

The Logical Tables folder contains the logical tables configured in the business model. If logical tables are not pertinent to a particular expression builder, the Logical Tables folder is not displayed.

When you select the Logical Tables folder, each logical table in the business model displays in the middle pane, and each column for the selected logical table displays in the right pane.

Operators

The Operators folder contains the available SQL logical operators.

Expressions

The Expressions folder contains the available expressions.

Functions

The Functions folder contains the available functions. The functions that appear depend on the object you selected.

Constants

The Constants folder contains the available constants.

Types

The Types folder contains the available data types.

Repository Variables

This folder contains the available repository variables. If no repository variables are defined, this folder does not appear.

Session Variables

This folder contains the available system session and non system session variables. If no session variables are defined, this folder does not appear.

Example of Setting Up an Expression

Figure 15 shows the expression builder for a derived logical column, with a blank expression.

Figure 15.  Expression Builder for Derived Logical Columns

Click for full size image

With the Functions folder selected in the left pane, double-clicking on the function in the right pane pastes the function in the expression builder's edit box. Clicking once between the parentheses of the function darkens that area, marking it as the insertion point.

Double-clicking on the logical column pastes the logical column into the insertion point as the argument of the function. Figure 16 shows where the expression appears in the window.

Figure 16.  Example Logical Column Function in the Editing Pane

 

Click for full size image

Navigating Within the Expression Builder

Use the following procedure to navigate within an Expression Builder dialog box.

To navigate within an Expression Builder

  1. In the Selection pane, select the appropriate folder for the type of expression you want to build.
  2. The available categories for the folder appear in the Categories pane.

  3. Select the appropriate category for the expression you want to build.
  4. The available building blocks for that category appear in the Building Blocks pane.

  5. Double-click a building block to move it into the Editing pane.
  6. To insert an operator into the expression, double-click an operator on the Expression Builder toolbar.

Building an Expression

Use this procedure to this procedure to build an expression in the Expression Builder dialog box.

To build an expression

  1. Navigate to the individual building blocks you want in the expression.
  2. The Syntax bar at the bottom of the Expression Builder dialog box shows the syntax for the expression.

  3. Add the building blocks to the Editing pane.
  4. Edit the building blocks to reflect the expression you want.
  5. Use the Expression Builder toolbar to insert operators into the expression.
  6. Repeat the preceding steps until the expression is complete, and then click OK.
  7. The Administration Tool displays a message for any syntax errors in the expression. When the expression is syntactically correct, the Administration Tool adds the expression to the dialog box from which you accessed the Expression Builder.


 Siebel Analytics Server Administration Guide 
 Published: 23 June 2003