I have a requirement like this:
Read a file (actually a text file uploaded to mainframe) line by line and copy next 8 bytes when a particular word is found in the record. E.g., if the input file is like the one below then the REXX code should give next 8 characters whenever say “Program:†is encountered i.e. output file for the below input file should have 2 records- M002233 and M1254789.
Description..
The purpose of this section is to put in ..
Job: J002233
Program:M002233
The purpose of this section..
The purpose of Program:M1254789
Note: position of tag like ‘Program:’ in above sample file is NOT fixed.
How to do this?
Thanks,
Shvndu