INDEX
Identifies the index name and the field(s) on which the index is based. You must define at least one index parameter.
You can define up to 128 index parameters.
Syntax
INDEXn=name,FIELDnn[,...FIELDnn],TYPE=type
Options and values
- n
- The index parameter identifier. When you add an index parameter,
use the next available number beginning with
1
. - name
- Determines the index name that is associated with the index value.
The index name can be a maximum of
250
bytes. It is recommended that you enter the name as a hexadecimal string. - FIELDnn
- Name of the field parameters that the 390 indexer uses to locate the index.
- TYPE=type
- You can specify type as follows:
Ensure that you enter value as a hexadecimal string.TYPE=GROUP,BREAK={YES[,INITVAL=value] | NO} [,KEEP={YES | NO}] TYPE=GROUPRANGE,BREAK=NO TYPE=GROUPRANGE2,BREAK=NO
Notes
- TYPE=GROUP must be specified for all indexes except:
- INDEX1 when INDEXSTYLE=PAGE
- INDEX2 when INDEXSTYLE=PAGE or PDOC
- INDEX3 when INDEXSTYLE=NODX
- TYPE=GROUPRANGE or TYPE=GROUPRANGE2 must be specified for:
- INDEX1 when INDEXSTYLE=PAGE
- INDEX2 when INDEXSTYLE=PDOC
- TYPE=GROUPRANGE must be specified for:
- INDEX2 when INDEXSTYLE=PAGE
- INDEX3 when INDEXSTYLE=NODX
- You can specify up to 32 FIELD parameters when you specify TYPE=GROUP. Separate field parameter names with a comma. When you specify multiple FIELD parameters on a single INDEXn parameter, each FIELD value is concatenated to form the index value. The total length of all the specified FIELD parameters cannot exceed 254 bytes. The FIELD values are ignored for indexes 1, 2, and 3 when you specify INDEXSTYLE=NODX.
- Only one FIELD value can be specified when TYPE=GROUPRANGE is specified.
- One or two FIELD values can be specified when TYPE=GROUPRANGE2 is specified.
- When TYPE=GROUPRANGE is used for:
- INDEX1 when INDEXSTYLE=PAGE
- INDEX2 when INDEXSTYLE=PDOC
INDEX1=X 'D3D6C1D56DD5E4D4C2C5D9C',FIELD1,(TYPE=GROUPRANGE) FIELD1=*,*,10,(OFFSET=(3:12),MASK= '##########' ,ORDER=BYROW)
- When TYPE=GROUPRANGE2 is used for:
- INDEX1 when INDEXSTYLE=PAGE
- INDEX2 when INDEXSTYLE=PDOC
When one FIELD subparameter is specified, it refers to both the begin range value and the end range value.INDEX1=X'D3D6C1D56DD5E4D4C2C5D9',FIELD1,(TYPE=GROUPRANGE2) FIELD1=0,3,10,(TRIGGER=3,BASE=0) TRIGGER3=*,46,X'4B',(TYPE=FLOAT) /* . */
This set of parameters is interpreted as the following:- For the begin range value: Start at the top of the page and scan down looking for a hexadecimal 4B in column 46 (per TRIGGER3). If found, then (per FIELD1=0,3,10) stay on this line (0), go to column 3 (3), and extract 10 positions (10).
- For the end range value: Start at the bottom of the page
and scan up looking for a hexadecimal 4B in column 46. If found, then
stay on this line, go to column 3 and extract 10 positions. For
x is the number of lines to move from the line where the trigger value was found. If 0, stay on this line. If negative, move up that number of lines. If positive, move down that number of lines. y is the column number to start from on the offset line. z is the number of positions to extract, starting with column y.FIELDn=x,y,z
When two FIELD subparameters are specified, the first refers to the begin range value and the second refers to the end range value.
- When you specify TYPE=GROUP, use BREAK=YES for index
values that must change to indicate that the current page is the start
of a new document. However, if the index value contains multiple fields which are to be concatenated together, only the first field is examined to determine if the current page is the start of a new document.
When you specify BREAK=YES, you can optionally specify the INITVAL=value parameter to give an initial value that the first field in the index value must change from before the first document is captured. This is one method to skip over alignment pages at the start of a print stream.
The following is an example. Note that this should be entered all on one line.
In this example, all pages at the start of the report file that contain a string of asterisks in the position of the ACCOUNT field are skipped over. The report starts capturing its first document when something other than a string of asterisks is found in that position.INDEX3=x'C1C3C3D8E4D5E3',FIELD2,(TYPE=GROUP,BREAK=YES, INITVAL=x'5C5C5C5C5C5C5C5C5C')
- When you specify TYPE=GROUP, you can optionally specify
the KEEP={YES | NO} parameter. This parameter can be used with any
TYPE=GROUP index.
When KEEP=NO is used, this is the same as not specifying the KEEP parameter at all. Each document in the load file must provide all of its own index values.
When KEEP=YES is used, the index value found for the first document in the load file is used for that index across all remaining documents in the load file. Two examples of when this might be useful are:
- The posting date field exists only in the first document of the load file.
- An AFP file generates multiple index rows per document, but the posting date TLE does not repeat for each generated index row.
- Refer to the INDEXSTYLE parameter for examples.