EXPRESSION
Using the Expression instruction you can create calculated dynamic columns using one or two columns from a database. You can create simple expressions or complex expressions. For example, a simple expression concatenates strings by joining several columns. A complex expression uses mathematical operations such as logarithms. For expressions that generate a decimal value, you can specify precision up to six decimal places.
An Expression instruction must have the following syntax:
Syntax
EXPRESSION [Target table] [Target column] [Expression]
Parameters
Target table
Define the target table where the expression column is created.
Target column
Defines the name of the new column. Do not use the following characters:
/ \ º ª - accents, dieresis, ?, !, *, @, #, &, $, o, ñ
Expression
The expression used to create a column value. To create expressions you use operators, statements, and functions.
BIRT Analytics Loader supports the following operators described in Table 5-4.
GE[>=], LE[<=],
EQ [=], NE[<>],
Table 5-5 presents the complete list of the functions. For more information about these functions, see Using BIRT Analytics.
Table 5-5  
Returns the left part of a string of characters, where n is the number of characters to return.
Returns a column based on random (n). For example, RAND (120) in the Customers table returns a column in which customers are randomly divided into 120 different groups.
Returns the square root of n, where n is the mean of the values of the column.
How to create an expression
This example creates a column that displays the total dollar amount of car inventory.
1  
2  
Figure 5-17  
3  
4  
5  
6  
7  
Figure 5-18  
8  
9  

Additional Links:

Copyright Actuate Corporation 2013 BIRT Analytics 4.2