The Range argument refers to view-time expanded rows and columns, on which calculations are performed after suppression. Sorting is performed after calculation is completed. The following table explains the expanded range notation:
Table 29. Range Notation
If a range is used, you can use any combination of the above range notations.
The following example points to expanded rows 5 through 10 in design-time row 2:
row[2(5:10)]
The following example identifies columns C through E in design-time column A:
column[A(C:E)]
The following example points to expanded rows 1, 3, 5, 6, 7, 8, 9, 10, 12, 13, 14, 15 and 17 in design-time row 2:
row[2(1,3, 5:10, 12:15, 17)]
When the grid contains suppression properties, expanded rows and columns may be suppressed. For information on suppressing data, see Conditional Suppression. |
If the Range argument refers to a number of expanded rows that is greater than the maximum number of rows expanded in the segment, the extra rows are ignored.
In the following example, expanded rows 6 through 10 are identified, but segment 1 contains only 3 expanded rows. In this situation, the function works only on expanded rows 6 through 8:
row[1(6:10)]
If none of the expanded rows in the Range exist, the entire axis reference is ignored.
The following example ignores the reference to 23 if segment 3 only contains 10 expanded rows:
row[3(23)]
If you enter a larger starting range than ending range, the system internally switches them around.
The following example shows how the range is reversed:
row[1(7:5)] becomes row[1(5:7)]
Multiple references to the same expanded rows or columns are valid. However, this may cause the same rows or columns to be included twice in an expression.
The following example sums expanded row 5 twice:
row[2(3,5,7,5)].sum
The following example specifies expanded rows 3, 4, 5, 6, 7, and row 5. It includes row 5 twice in the calculation of the average:
row[2(3:7,5)].ave
The syntax for a range in a segment range is:
AXIS[Segment Start : Segment End (Range Start : Range End)]
where Segment Start and Segment End refers to multiple segments.
The following example points to expanded rows 5, 6, and 7 in row segments 1, 2, 3, and 4:
row[1:4(5:7)]
The following example points to expanded rows 5, 7, and 9 in row segments 1, 2, 3, and 4:
row[1:4(5,7,9)]
If the segment argument refers to segments that do not exist in the axis, the segments are ignored. This includes suppressed rows or columns.
The following example points to expanded rows 4, 6, 7,8, 9, and 10 in row segment 1 and 4, 5, and 6 in row segment 3 and all expanded rows in row segment 7:
row[1(4, 6:10); 3(4:6); 7]