Data Types and Formatting
As a developer and object designer, you define the attributes of User-Defined VARA Objects on the Variables page or on the Attributes sub page (for STATIC and XML VARA objects). In the Data & Formatting section, you specify the data type and format of the value that is rendered by the VARA object.
Note: The data type of BACKEND and FILELIST VARA objects is always Text and it cannot be changed. The data type of EXEC, MULTI, SQL, SEC_SQL, SQLI, SEC_SQLI and STATIC can be changed at any time.
This page includes the following:
Data Type: Text
Enter an alphanumeric string. The system removes blanks at the end of the string, leading blanks are kept.
For VARA objects with this data type you also define the following parameters:
-
Limit Text Length (All VARA types)
Sets a limit to the length of the character string
For STATIC VARA objects: The content length is unlimited. If you activate this option, this restriction affects the first value column only.
-
Max. text length (All VARA types)
Possible values: 1 to 1024
-
Force upper case (All VARA types)
Converts the text of the first value column to upper case
-
Result format (BACKEND, MULTI, SQL, SQLI, SEC_SQL and SEC_SQLI VARA objects)
Defines the format of the content in the RESULT column, which is the first column that is displayed in the preview. The result column can show a combination of value columns and any other characters.
Column numbers that are specified in curly brackets { } in the Result Format field are replaced by the value of the relevant column.
Example:
- Value column 1: JOB1
- Value column 2: WIN01
- Result format: {1}_{2}
- Result column: JOB01_WIN01
If you do not specify a result format, the value in the Result or in the Key column is used.
Important!
- The result must be within the defined limits and it must match the data type. Otherwise, the result column does not show a value.
- The limitations (min. value, max. value, limit text to) do not affect the result column but the first returned column. If the values of this column exceed the maximum range, this line is skipped. The line is not available through the VARA object.
-
Scope (SEC_SQL and SEC_SQLI VARA objects)
Simplifies the script that writes values to variables or reads them
Usually, the key must be specified as a parameter in the script element :PUT_VAR or GET_VAR. However, this makes it difficult to ensure that values are stored with unique keys. By specifying a particular scope, you simplify the design of scripts that write to or read from the VARA object.
For Freely selected, specifying a key is optional. For all other scope values, if no key is specified, the default depends on the task that accesses it.
This list describes what happens if you use this setting:
-
No scope
Default key if none is specified: *
-
Freely selected
If a key is not specified, the Runtime error U00003712 occurs.
-
Host - each host name
Default key if none is specified: Name of the Agent where the task is running
-
Task - each task name
Default key if none is specified: Name of the task
-
Workflow name - each workflow name
Default key if none is specified: Name of the parent Workflow of the task
-
Workflow session - each workflow session
Default key if none is specified: RunID of the parent Workflow of the task
-
User - each user name
Default key if none is specified: Name of the executing user
-
User session - each user session
Default key if none is specified: RunID of the user session
The entry (row) corresponding to the user session is deleted when the user session ends.
-
-
Sort by Column (for STATIC VARA objects only)
Specifies the column that is used to sort the entries
Possible values: Key, Value 1, Value 2, Value 3, Value 4, or Value 5.
-
Sort Order (for STATIC VARA objects only)
Possible options: Descending or Ascending.
The underlying type of sorting, such as binary or alphabetic, depends on what is defined in your database.
Data Type: Number, Time, Date, Timestamp
For VARA objects with these data types you also define the following parameters:
-
Output format (All VARA types)
-
For Number
Singed integer, possible values: any number from 0 to 2147483647
Default format: 16 digits
-
For Time
The following formats are possible:
- HHMMSS
- HH:MM:SS
- HHMM
- HH:MM
- MMSS
- MM:SS
Default format: HHMMSS
The value for this data type must be a four or a six digit number. Decimal places are removed. Four-digit numbers are converted to hours and minutes.
Example:
Output Format: HH:MM:SS
Value of the user or the data source: 1234, 1234.5, 123400, 12:34, 12:34:00
Resulting variable value: 12:34:00
-
For Date
The following formats are possible:
- DD-MON-YYYY
- DD-MON-RR
- MM-DD-YYYY
- YYYYMMDD
- MMDDRR
- DDMMRR
- MM-DD-RR
- MM/DD/RR
- YYMMDD
- YY.MM.DD
- YY-MM-DD
- YYYYMMDD
- YYYY.MM.DD
- YYYY-MM-DD
- DDMMYY
- DD.MM.YY
- DD-MM-YY
- DDMMYYYY
- DD.MM.YYYY
- DD-MM-YYYY
- MMDDYY
- MMDDYYYY
- MM/DD/YY
- MM/DD/YYYY
Default format: YYMMDD
Note: Some date formats include RR as a placeholder for the abbreviated year. Having both YY and RR accommodates different century-counting conventions, which are based on the two digits of the abbreviated year value.
- YY - The current century applies for numbers from 00 to 80. The previous century applies for 81 - 99.
- RR - The current century applies for numbers from 00 to 49. The previous century applies for 50 - 99.
Examples:
-
Date format DDMMYY and the resulting complete dates:
010305 - corresponds to 01 March 2005
010365 - corresponds to 01 March 2065
010380 - corresponds to 01 March 2080
010385 - corresponds to 01 March 1985 -
Date format DDMMRR and the resulting complete dates:
010305 - corresponds to 01 March 2005
010365 - corresponds to 01 March 1965
010380 - corresponds to 01 March 1980
010385 - corresponds to 01 March 1985
-
For Timestamp
Possible formats:
- YYYYMMDDHH24MISS
- YYYY-MM-DD HH:MM:SS
Default format: YYYY-MM-DD HH:MM:SS
The value for this data type must be a four or a six digit number. Decimal places are removed. Four-digit numbers are converted to hours and minutes.
Example:
Output Format: YYYY-MM-DD HH:MM:SS
Value of the user or the data source: 20110325 2201, 20110325 2201.5, 20110325 220100
Resulting variable value: 2011-03-25 22:01:00
Notes:
- In STATIC VARA objects, the first column is Value 1
- In Database and MULTI VARA objects, the first column is the first basic column. MULTI VARA objects use the first basic column as their reference column. For this reason, the output format of the source variable can affect the values that are retrieved.
- The output format of STATIC VARA objects can be changed at any time. The values are converted to the new format. However, they are not converted if the values do not match the old format.
- The format that is used to enter values in STATIC VARA objects is irrelevant unless it is an AE-supported format of the data type in question. The values are then converted to the relevant output format.
-
-
Set Min. value / Min. value and Set max. value / Max. value (All VARA types)
Enforces a minimum/maximum value.
Possible values for Number: max. 16 digits before and 16 digits after the decimal point
-
Result Format (for MULTI, SQL, SQLI, SEC_SQL, SEC_SQLI)
Defines the format of the content in the RESULT column, which is the first column that is displayed in the preview. The result column can show a combination of value columns and any other characters.
Column numbers that are specified in curly brackets { } in the Result Format field are replaced by the value of the relevant column.
Example:
- Value column 1: JOB1
- Value column 2: WIN01
- Result format: {1}_{2}
- Result column: JOB01_WIN01
If you do not specify a result format, the value in the Result or in the Key column is used.
-
Scope (for SEC_SQL, SEC_SQLI)
See the description at Scope (SEC_SQL and SEC_SQLI VARA objects) above
-
Sort by column (STATIC)
Specifies the column that is used to sort the entries
Possible values: Key, Value 1, Value 2, Value 3, Value 4, or Value 5
-
Sort by order (STATIC)
Possible options: Descending or Ascending
The underlying type of sorting, such as binary or alphabetic, depends on what is defined in your database.
Changing the Data Type
Changing the data type of a VARA object is possible except for BACKEND, FILELIST and XML.
Notes:
- After you have defined Number, Timestamp, Time, and Date data types, you can change them to Text. The resulting values are converted without any changes.
- You cannot modify the data types Number, Timestamp, Time, and Date directly. First, you must convert them to Text.
- After you have defined Text data types, you can change them to Number, Timestamp, Time, or Date only if the Output format is defined. When you save the VARA object, the system verifies that the values match the specified format.
- Only the entry of the Value 1 column is checked against the data type for plausibility. You can enter any value in the remaining Value columns.
See also: