How many is "so many"? Is it more than 100? PARSE can handle 100 fields at a time.
You mention three fields, but your required output only shows two.
If you can get us some more detailed information...
Thanks Bill for the quick reply....
Yes my o/p will only contain two fields
I have around 24 fields in front of the required field , I have used ENDBEFR for such kind of requirement earlier
but is it possible to achieve this by some other command or skipping few fields instead of extracting each
You can use DFSORT PARSE function to scan upto 100 fields. You can ignore the ones you don't need. Since your input is a VB file your actual data starts from position 5. Use the following DFSORT JCL which will create a VB file with the fields 2 and 4.
The reason your sort card did not work is you trying to overlay the RDW of the VB file. You canNOT overlay the contents of RDW. If you want an FB file then add the following statement. The 3 fields you interested are (12+18+18 =48 bytes)
What do you mean by the sort card being too lengthy? It'll be as long as it needs to be, and needn't be longer. If that is in some way too long, then you'll have to look for another solution, maybe write a program.
Making the output dataset FB is not a problem.
I asked about the start positions and lengths of your output fields, as in what they are, rather than do you have them as a yes/no answer. You currently have "gaps" from the latest you have shown. Do you want those as well?