ScriptEigener Objekttyp in der Automation Engine function: Retrieves information from a data sequence.
Syntax
GET_PROCESS_INFO(Data sequence reference, Information, [Line ])
Syntax |
Description/Format |
---|---|
Data sequence reference |
The reference to the data sequence whose nformation should be read. |
Information |
The specific Information that should be retrieved Allowed values:
|
Line |
The line whose column number should be determined. This parameter can only be specified if the number of columns is queried (Information = COLUMNS). |
Return code |
---|
Information from the data sequence |
Comments
This script function allows you to retrieve general information (such as the number of columns or lines) of data sequences. To do so, you must specify the reference of the data sequence and the information that should be read.
When the number of columns should be read, you can additionally specify the corresponding line. If no line is given the used line depends on the usage of the script element:
The information INDEX stipulates that the function is used inside a process loop. In this case the number of the line is retrieved that is currently processed by the loop.
When reading the number of rows there are no special dependencies.
Note that the specified data sequence must exist and must not closed by the element :CLOSE_PROCESS. Otherwise, a runtime error will occur.
Examples
The following example shows the creation of a data sequence that is filled with the entries of a VariableSpeichert oder ermittelt Werte dynamisch zur Laufzeit. Auch ein eigener Objekttyp in der Automation Engine. object. Then the number of columns are determined per line and printed to the activation report.
:SET &HND# = PREP_PROCESS_VAR(VARA.SQL,"*WIN*")
:SET &LNR# = GET_PROCESS_INFO(&HND#, ROWS)
:PROCESS &HND#
:SET &IND# = GET_PROCESS_INFO(&HND#,INDEX)
:SET &COL# = GET_PROCESS_INFO(&HND#,COLUMNS,&IND#)
:PRINT "Line &IND# / &LNR# has &COL# columns"
:ENDPROCESS
:CLOSE_PROCESS &HND#
See also:
Script element | Description |
---|---|
Discards an unnecessary data sequence. |
|
Loop for line by line processing of a data sequence - a sequential file or a command result, for example. |
|
Returns the content of the current line of a data sequence. |
|
PUT_PROCESS_LINE | Adds a line to a certain data sequence |
Script Elements - Data Sequences
About Scripts
Script Elements - Alphabetical Listing
Script Elements - Ordered by Function