CHGPF doesn’t change the based on LFs

25 pts.
Tags:
CHGPF
i5/OS
Logical Files
Physical Files
I used the CHGPF command to change the record layout of a Physical File but the based on Logical Files were NOT changed - the Format Level Identifier still had the old value. 

Software/Hardware used:
iSeries (AS/400) - i5/OS V5R4M0

Answer Wiki

Thanks. We'll let you know when a new response is added.

By using CHGPF command The Format level identifier for LFs will not change and it will be refering to the old identifier. You will get the new identifier once you recompile the LF.

Discuss This Question: 8  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • TomLiotta
    ...but the based on Logical Files were NOT changed - the Format Level Identifier still had the old value. That's right. That's what should happen as long as you only changed the PF and didn't change any LFs. If you didn't change any LFs, how could their format IDs be any different? That's a major point in the purpose of the CHGPF command. You can make changes to an underlying PF without disturbing all of the LFs that are built over it. Tom
    125,585 pointsBadges:
    report
  • QCDT
    Thanks for the feedback guys! I regularly use the CHGPF command to add new fields to a PF. I have found that all based on LFs (that DO NOT specify fields - the DDS specifies only the key fields and possibly some select/omit criteria) also DO get changed automatically to the new record format level identifier. Sometimes - and only sometimes - I have encountered a situation where some (but NOT all) LFs will get changed to the new record format level identifier. ALL the LFs have the same record format NAME as the PF and definitely were not locked at the time the CHGPF command was run. So I canot figure out why some LFs DO get changed and others DO NOT get changed.
    25 pointsBadges:
    report
  • philpl1jb
    Grasping here... The CHGPF should change the logicals. The logicals that didn't change - had the same record name - did not contain a field list - were actually targeted on the correct pf - had maint *IMMED attribute - are shown on the list of DSPDBR for the physical file - do not use the format keyword - was the logical still usable? Phil
    49,850 pointsBadges:
    report
  • TomLiotta
    that DO NOT specify fields You're right; I was thinking along the normal "explicit" field list lines where the LF is effectively an explicit "view". If it's a shared format, then it's not quite just a "view" -- the LF is primarily an access path. When fields are explicitly listed, the field definitions are used as a "view" into the physical data. But an implicit field list should inherit from the record format. Can you provide output from DSPFD <LF> TYPE(*RCDFMT) along with the associated DSPFD <PF> TYPE(*RCDFMT) for one of the suspect LFs? Tom
    125,585 pointsBadges:
    report
  • QCDT
    [...] 9. Deepu9321, TomLiotta, QCDT, and Philpl1jb gave some suggestions for a user whose CHGPF doesn’t change the based on logical files. [...]
    0 pointsBadges:
    report
  • QCDT
    Hi Folks - I've got some more interesting information about this issue where the CHGPF will sometimes NOT change the record format level identifier of all LFs! When I use the DSPDBR command I can see all the LFs. However, when I use the DSPDBR command and specify the Record format (RCDFMT) then I see fewer LFs. All LFs incidentally have the same record format name! The reason why some LFs have disappeared from the DSPDBR (with RCDFMT specified) is due to previously running a CHGPF to change the CCSID - this "breaks the links" between the PF and the LFs - but all LFs are still valid and useable! The LFs that are still visible had been created after the CHGPF to change the CCSID had been run. When another CHGPF is used to actually change the PF structure (adding a new field) then the system will only change the LFs that are visible in the DSPDBR with RCDFMT specified. For example - create a PF called ORDERS. Then create two LFs: ORDERSL1 and ORDERSL2. The DSPDBR command and DSPDBR with RCDFMT specified will show both LFs. Then use CHGPF to change the CCSID of ORDERS. The DSPDBR command will show both LFs but the DSPDBR with RCDFMT specified will show NO LFs! Create two more LFs: ORDERSL3 and ORDERSL4. The DSPDBR command will show all four LFs but the DSPDBR with RCDFMT specified will show only the two new LFs ORDERSL3 and ORDERSL4. Then, if I change the DDS of the PF ORDERS and add a new field - then use this changed DDS source in a CHGPF - the PF ORDERS and the LFs ORDERSL3 and ORDERSL4 will have the new record format level identifier - but LFs ORDERSL1 and ORDERSL2 will not. Try it yourself and see! Problem solved - many thanks to all for all the feedback!
    25 pointsBadges:
    report
  • BigKat
    actually, I would not say the problem is solved, so much as it is now accurately (and reproducibly) defined.
    8,100 pointsBadges:
    report
  • QCDT
    [...] CHGPF doesn’t change the based on LFs [...]
    0 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following