Infogix ACR user programs, such as Delimited Field Access (UUPDLIM), revise the way an input source is processed. UUPDLIM extracts each delimited field as its own record, making it possible to use a static position and length to extract data from a delimited file.
Problem
You need to extract data from a delimited file, such as a trade file that contains data delimited with commas. You do not want to process the header records in the file. Or you may want to begin the data extraction with a particular record.
Solution
Use the Delimited Field Access user program (UUPDLIM) to extract data from delimited files. See the ACR User Program Guide. Specify the Sequence ID parameter (/s) to put the sequence numbers on the record (0000000100000001, 0000000100000002, and so on). The first eight characters of the sequence represent the record number; the second eight characters represent the field number on the record.
Complete the following steps to extract only the required information :
1 ) To begin processing the data records, but not the header record, in a file with one header record, set up the following SELECT condition :
SELECT if position 1 for a length of 8 is not equal to 00000001
This parameter will not extract the data that appears in the header record.
Adjust the statement to accommodate a file with multiple header records or to skip some records and begin processing with a record that appears later in the file.
2 ) Select the fields you want to extract, based on their field number.
SELECT if position 1 for a length of 8 is not equal to 00000001
SELECT if position 9 for a length of 8 is not equal to 00000004
The example above selects field 4, which is not in the header record.
Comments
0 comments
Please sign in to leave a comment.