User Tools

Site Tools


Introduction | Session 1 | Session 2 | Session 3 | Session 4 | Session 5 | Session 6 | Session 7 | Session 8

Session 4: Processing Object Data

Estimated completion time → 10 minutes.

There are many tools available in EASA to process and manipulate data, data may be entered by a User or read from an outside source, such as a database, spreadsheet or text file.

The object under which all the available data processing tools reside is DATA PROCESSING.

A DATA PROCESSING itself has no parameters, it is a Parent for SCALAR and LIST data and related processing.

A SCALAR contains a single value, while a LIST is a sequence of one or more values.

Please follow the instructions below to complete this practical session.


COMPUTE, MAP and EXPAND

The first DATA PROCESSING we use is a COMPUTE.

A COMPUTE is an expression that evaluates to a value.

  • On the EASA pages select EASA→Set Mode→Author
  • Open EASAP Builder
  • Expand the USER INTERFACE branch

The first DATA PROCESSING objects to create are COMPUTE objects that will store logical expressions that determine whether any filtering of data is performed when the stock data is read from the database.

  • Expand data_processing_Stock_Analysis by clicking on its (+)
    • Right-click SCALAR
      • Select Child→Add COMPUTE
        • Rename it compute_Exchange
          • Set,
Parameter Name Parameter Value
Value:inputbox_Exchange == "" ← two empty double-quotes for empty string

For the above expression the value will either equal 1.0 or 0.0 depending on if the expression is true or false.

In step 7, you will use an object reference (historically 'DOR') to refer to compute_Exchange for use in a MAP.

Let’s create a similar COMPUTE for inputbox_Sector.

  • Right-click compute_Exchange
    • Select Copy
  • Right-click compute_Exchange again
    • Select Paste (Sibling)
  • Rename it compute_Sector
    • Set,
Parameter Name Parameter Value
Value:inputbox_Sector == "" ←two empty double-quotes for empty string

Create a third COMPUTE for inputbox_Field_Name

  • Right-click compute_Sector
    • Select Copy
  • Right-click compute_Sector again
    • Select Paste (Sibling)
      • Rename it compute_Query
        • Set,
Parameter Name Parameter Value
Value:inputbox_Field_Name =="" ←two empty double-quotes for empty string

Let's add a series of MAP's to store values to be used in a WHERE clause for a SQL query that will read the stock data from the database.

  • Right-click compute_Query
    • Select Sibling→Add MAP
      • Rename it map_Exchange
        • Set,
Parameter Name Parameter Value
Value:compute_Exchange
Inputs:1.0,0.0
Outputs:,AND Exchange = '%inputbox_Exchange%'

The Outputs: parameter value needs to have a space in front of the comma.

map_Exchange is a mapping that takes a particular value of compute_Exchange (the Inputs: field) and sets map_Exchange to a corresponding value (the Outputs: field).

  • If compute_Exchange equals 1.0,
    • map_Exchange will have a value of a space.
  • If compute_Exchange equals 0.0,
    • map_Exchange will have a value of ‘AND Exchange = 'inputbox_Exchange
      • (notice the percent signs disappear after the object reference is recognized)

An object reference to map_Exchange will be used in the SQL statement as described in Session 5

  • Right-click map_Exchange
    • Select Copy
  • Right-click map_Exchange again
    • Select Paste (Sibling)
      • Rename it map_Sector
        • Set,
Parameter Name Parameter Value
Value:compute_Sector
Inputs:1.0,0.0
Outputs:,AND Sector = '%inputbox_Sector%'

Again, the Outputs: parameter value must have a space in front of the comma.

  • Right-click map_Sector
    • Select Copy
  • Right-click map_Sector
    • Select Paste (Sibling)
      • Rename it map_Query
        • Set,
Parameter Name Parameter Value
Value:compute_Query
Inputs:1.0,0.0
Outputs:,AND %inputbox_Field_Name% %inputbox_Operator% %inputbox_Value%

Again the Outputs: parameter value must have a space in front of the comma.

  • Right-click map_Query
    • Select Sibling→Add EXPAND
      • Rename it Financial_Query
        • Set,
Parameter Name Parameter Value
Value:%inputbox_Field_Name% %inputbox_Operator% %inputbox_Value%

The Value: parameter setting has a space in-between the ‘%’ symbols.

EXPAND is used to define one or more lines of text.

In the instance above, the EXPAND will become a string of text comprised of each object reference in Value: separated by a space.

  • Right-click map_Query
    • Select Copy
  • Right-click map_Query
    • Select Paste (Sibling)
      • Rename it map_Query_Report
        • Set,
Parameter Name Parameter Value
Value:compute_Query
Inputs:1.0,0.0
Outputs: , %Financial_Query% ← intial <SPACE> on this line
  • Save the EASAP, click on the Save button or type CTRL-s

The EASAP Tree should look similar to the following,

We have completed Session 4 and we may either proceed to the next session or take a break and exit out of EASAP Builder.

Introduction | Session 1 | Session 2 | Session 3 | Session 4 | Session 5 | Session 6 | Session 7 | Session 8


Page Tools