Data specifications in GET and PUT statements specify the data to be transmitted.
If a GET or PUT statement includes a data list that is not preceded by one of the keywords LIST, DATA, or EDIT, LIST is the default.
On output, a data list item for edit-directed and list-directed data specifications can be an element expression, an array expression, or a structure expression. For a data-directed data specification, a data-list item can be an element, array, or structure variable. It must not be locator-qualified. It can be qualified (that is, a member of a structure) or string-overlay-defined.
The data types of a data-list item can be any computational data (as long it does not have the CONSTANT or VALUE attribute), and in PUT statements, the data type may also be POINTER, HANDLE, OFFSET, ENTRY, FILE or LABEL. If the data type is one of these non-computational types, then the contents of the item will be transmitted via its heximage (and for PUT DATA, the heximage will be enclosed in quotes followed by a suffix of BX).
An array or structure variable in a data-list is equivalent to n items in the data list, where n is the number of element items in the array or structure. For edit-directed transmission, each element item is associated with a separate use of a data-format item.
When the last repetitive specification is completed, processing continues with the next data-list item.
Each repetitive specification must be enclosed in parentheses, as shown in the syntax diagram. If a data specification contains only a repetitive specification, two sets of outer parentheses are required, since the data list is enclosed in parentheses and the repetitive specification must have a separate set.
When repetitive specifications are nested, the rightmost DO is at the outer level of nesting. For example:
get list (((A(I,J)
do I = 1 to 2)
do J = 3 to 4));
There are three sets of parentheses, in addition to the set used to delimit the subscripts. The outermost set is the set required by the data specification. The next set is that required by the outer repetitive specification. The third set of parentheses is required by the inner repetitive specification.
This statement is equivalent in function to the following nested do-groups:
do J = 3 to 4;
do I = 1 to 2;
get list (A (I,J));
end;
end;
It assigns values to the elements of the array A in the following order:
A(1,3), A(2,3), A(1,4), A(2,4)