Create a complex and a dynamic complex variable

Use a complex variable to hold tabular or array-based data values, such as a list of product details.

Two kinds of complex variables are available:

Create a complex variable

Static complex variables are an array (group) of variables of potentially different data types. Static complex variables keep their cell mappings to process variables throughout the job. Every time a mapped variable value is updated in the job, it is reflected in the static complex variable cell.

A static complex variable can only be created for a process; it cannot be created as a server variable.

  1. In the New variable dialog box, enter a unique Name for the variable.
    By default, the name of the variable becomes the ID of the variable; however, you can change the ID if needed.
  2. On the Type list, select Complex. (Default: String)
  3. By default, Column1 is added. To add more columns, do the following:
    1. Click for Columns.

      By default, the column Name is displayed as Column2. You cannot edit the column name.

    2. On the Type list select the column.
    3. Click Add.
    4. Add more columns as needed.

      You can modify and delete a column. You can only delete the most recently added columns.

  4. To configure the variable content, click Configure contents.

    The Configure complex variable content or Configure dynamic complex variable content page appears depending on the selection. By default, single row is added under each column.

  5. To configure the number of rows for the complex/Dynamic complex variable (initially, if it is dynamically updated), enter or select the No. of rows (default: 1) and then click Apply.
    The selected number or rows are displayed under each column. For example, if you have added two columns, and select the No. of rows as 6, six rows are added under Column1 and Column2.
  6. You can increment or decrement the value for number of rows. For example, if you have 2 columns and 6 rows, if you decrement the number of rows by 3 and click Apply, 3 rows are deleted, but the same number of columns (2) are retained.

    You can only delete the most recently added rows.

  7. For each column, do the following:
    1. Select Type, such as Bool.
    2. Provide a dynamic value (by mapping process or server variable) or enter a static value for each cell within a column.

    You can update the type of the column while configuring the variable. If you change the type, all the cell values within that column are discarded so that you can provide the value depending on the type.

  8. Click Add and close.

    A static complex variable retains its variable mappings throughout the job. Every time a mapped variable value is updated in the job, it is reflected in the static complex variable cell.

  9. Save the process.

Create a dynamic complex variable

Dynamic complex variables keep their cell mappings to process variables only until they are updated in the job. They are stored against the job and their array size and values can change during the course of the job.

At design time, you can create a complex variable with a maximum of 1000 cells, such as1000 X 1, 500 X 2, or 5 X 200. However, at runtime, no maximum limit is placed on the number of cells.

Dynamic complex variable can also be created as a server variable. Both types of variables are created in the same way. However, the Process Initialization option is not available when setting up complex server variables.

Variable members can be either dynamic or static. A static value is one that a user can enter but cannot modify.

  1. On the Type list, select Dynamic complex. (Default: String)
  2. By default, Column1 is added. To add more columns, do the following:
    1. Click for Columns.

      By default, the column Name is displayed as Column2. You cannot edit the column name.

    2. Select the column Type.
    3. Click Add.
    4. Add more columns as needed.

      You can modify and delete a column. You can only delete the most recently added columns.

  3. To configure the variable content, click Configure contents.

    The Configure complex variable content or Configure dynamic complex variable content page appears depending on the selection. By default, single row is added under each column.

  4. To configure the number of rows for the complex/Dynamic complex variable (initially, if it is dynamically updated), enter or select the No. of rows (default: 1) and then click Apply.
    The selected number or rows are displayed under each column. For example, if you have added two columns, and select the No. of rows as 6, six rows are added under Column1 and Column2.
  5. You can increment or decrement the value for number of rows. For example, if you have 2 columns and 6 rows, if you decrement the number of rows by 3 and click Apply, 3 rows are deleted, but the same number of columns (2) are retained.

    You can only delete the most recently added rows.

  6. For each column, do the following:
    1. Select Type, such as Bool.
    2. Provide a dynamic value (by mapping process or server variable) or enter a static value for each cell within a column.

    You can update the type of the column while configuring the variable. If you change the type, all the cell values within that column are discarded so that you can provide the value depending on the type.

  7. Click Add and close.

    • For a dynamic complex variable, the number of rows and columns is dynamic; they are not set at design time but are based on the return result set, such as a web service or database query.

    • The variable mappings for dynamic complex variable cells are only for initial creation and are not retained. A static complex variable retains its variable mappings throughout the job. Every time a mapped variable value is updated in the job, it is reflected in the static complex variable cell.

  8. Save the process.