----- Message from "Stone, Joel" <Joel.Stone@xxxxxxxxxx> on Wed, 26field.
Oct 2016 17:20:11 +0000 -----
"'COBOL Programming on the IBM i (AS/400 and iSeries)'" <cobol400-
Re: [COBOL400-L] PF / LF files
Copybooks should be avoided for file layouts. Does DDS exist for
the file? Did you add the new field to the DDS source code?
For old legacy apps, copybooks were created instead of DDS specs.
But I think that you need DDS to create an LF. Or you can do it
with SQL also.
Look at the LF or PF with DSPFD filename.
You will know that an LF was set up properly when the desired key
shows up in DSPFD under the "Access Path Description" area and your
new key field appears as "Key field ..................CustID" where
CustID is your new key field.
If you have DBU that is easier - the new field should be identified
as a key field. Press F4 to see K01, K02, K03... etc on each field.
When you compile the pgm, it will automatically bring in the new key
As an Amazon Associate we earn from qualifying purchases.
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.