Thanks DAvid.... In addition, I want to eliminate the FORMAT option, but wanted to use 2 physical files having 2 different record layouts. Is this possible ? I just would like to pick-up the required fields. Can MAPFLD option do the trick ? TIA
It is possible if there are common fields between the 2 files so that you can join them. Look at the JFLD parameter. You may need *MAPFLD to pick the proper field if the fields have the same name in both files.
Ted, Based on my posted source code, the 2 files I joined have distinct field names, I used a JFLD and a FORMAT parms. I want to eliminate the FORMAT parm. My concern is how to pick and choose the resultant fields out of the total fields from files A and B. File A File B A1 key field B1 A2 B2 A3 B3 I want to include A1, A2 and B2 fields in the result if A1= B1. My question is what should I include in my MAPFLD or MAPFLD is not needed because of the unique field names? TIA
You can't eliminate the FORMAT parm when you join files. You'll have to create a physical file that has the fields you need. You don't have to put any data in it or even put a member in it. Use that file in the FORMAT parm & make your HLL program read that file. If all of the fields in the FORMAT file are found in one file or the other, not in both, you won't need the MAPFLD parm.
Comment