Extractors
Extractors represent the location of a field within a record, or of a subfield within a composite. You extract fields from a composite using a Nth field extractor, while you extract fields from a record using Nth field, ID Node, or Fixed Position extractors.
Note:
To use Nth Field or ID Node extractors for a field or composite in a record, the field delimiter must be specified. To use these extractors for a field in a composite, the subfield delimiter must be specified. If these extractors are used without the appropriate delimiter set, the field values will not be returned correctly.
Nth Field. Counting from zero (0),
Position indicates the position of the field that you want to extract from the record. This value cannot be null and must be an integer greater than or equal to zero (0). For example, if you type 1, the second field will be extracted. This option is available only if you specified a field delimiter when configuring your flat file schema. This extractor returns the field as a key–value pair. The key is the name of the field. The value is the String value of the field.
Software AG recommends that you use this extractor instead of ID node.
ID Node. This extractor is a variation of the
Nth Field extractor and is available for backward compatibility for users of the
webMethods Module for EDI. Counting from zero (0),
Position indicates the position of the field that you want to extract from the record. This value cannot be null and must be an integer greater than or equal to zero (0). This extractor returns the field as a key–value pair. The key is the name of the field. The value is an IS document (IData object) containing a key–value pair in which the key is always “code,” and the value is the String value of the field.
Software AG does not recommend that you use the ID node extractor.
Fixed Position. Counting from zero (0), extracts a fixed number of bytes from a record.
Start Position. First byte to extract from the record.
End Position. First byte that is not included in the extraction. If you enter a negative number (for example, –1), the extractor returns all bytes from the byte specified in the
Start Position to the last byte in the record or composite.
For example:
record = webMethods
Start Position = 1
End Position = 7
Extracted bytes = ebMeth