Suffixed Data Elements

Restriction: This topic applies only when the AppMaster Builder AddPack has been installed, and applies only to Windows platforms.

The iterative expression syntax for numerically suffixed data elements is:

dataitem-#startnumber[/endnumber[/increment]]

Where the parameters are:

#

The pound sign (#) indicates the starting number of an iteration.

startnumber

Starting number of the iteration. Leading zeros in startnumber are generated in the SUM or SOURCE statements.

/

The first slash separating numeric descriptors of an iteration translates to THRU, the second slash to BY.

endnumber

Top limit of the increment range, or bottom limit if the increment is negative.

increment

The increment is the number by which the iteration is incremented; default is 1.

For example:

SOURCE MONTH-#1/6 BLANK WHEN ZERO

Generates an iteration of six SOURCE statements, suffixed numerically, 1 through 6, for example, MONTH-1 through MONTH-6. If you specify only one number, the iteration assumes the starting number to be 1. For example, SOURCE MONTH-#6 is equivalent to SOURCE MONTH-#1/6.

Without the iterative expression, you would code the previous statement, SOURCE MONTH-#1/6 BLANK WHEN ZERO, as follows:

SOURCE MONTH-1 BLANK WHEN ZERO
SOURCE MONTH-2 BLANK WHEN ZERO
SOURCE MONTH-3 BLANK WHEN ZERO
SOURCE MONTH-4 BLANK WHEN ZERO
SOURCE MONTH-5 BLANK WHEN ZERO
SOURCE MONTH-6 BLANK WHEN ZERO

For example, the following four SUM statements:

SUM MONTH-9-DATA
SUM MONTH-10-DATA
SUM MONTH-11-DATA
SUM MONTH-12-DATA

Can instead be coded as:

SUM MONTH-#9/12-DATA

This next example increments an iteration of SOURCE statements by 2 instead of the default 1.

SOURCE ELEMENT-#6/12/2

Which generates:

SOURCE ELEMENT-6
SOURCE ELEMENT-8
SOURCE ELEMENT-10
SOURCE ELEMENT-12

The PIC clause for each SUM or SOURCE statement generated by the iterative expression is taken from the mock-up. AMB matches the mock-up and detail line data item descriptions as the increment statements generate.