Midrange News for the IBM i Community


Posted by: neilrh
A/P
Jackson, MI
Subfile strangeness
has no ratings.
Published: 20 Apr 2012
Revised: 23 Jan 2013 - 1703 days ago
Last viewed on: 22 Sep 2017 (4274 views) 

Using IBM i? Need to create Excel, CSV, HTML, JSON, PDF, SPOOL reports? Learn more about the fastest and least expensive tool for the job: SQL iQuery.

Subfile strangeness Published by: neilrh on 20 Apr 2012 view comments(4)

Return to midrangenews.com home page.
Sort Ascend | Descend

COMMENTS

(Sign in to Post a Comment)
Posted by: bobcozzi
Site Admin ****
Chicagoland
Comment on: Subfile strangeness
Posted: 5 years 5 months 4 days 6 hours 44 minutes ago

In PGM2 is the display file declared with the INCLUDE or IGNORE keywords?

If you have INCLUDE(...) do you have only the record formats you are using the PGM2? If not then all formats are in PGM2 whether you use them or not.

Posted by: neilrh
Premium member *
Jackson, MI
Comment on: Subfile strangeness
Posted: 5 years 5 months 4 days 6 hours 9 minutes ago

PGM2 uses the INCLUDE keyword on the display file, with only the record formats used in that program.

Posted by: bobcozzi
Site Admin ****
Chicagoland
Comment on: Subfile strangeness
Posted: 5 years 5 months 4 days 4 hours 14 minutes ago

Test PGM2 by adding/including the subfile in the INCLUDE keyword. Then issue a dummy read/write to it but never execute those statements. Then see if you have different results.

If so, it may be that there is an issue with SHARED ODP and the INCLUDE/IGNORE keywords in RPG.

Posted by: neilrh
Premium member *
Jackson, MI
Comment on: Subfile strangeness
Posted: 5 years 5 months 4 days 4 hours ago

That does not seem to be the issue.

I've been reading through the IBM manuals, and they state that when RSTDSP is set for a display file, when you display another screen (PGM2 calls both PGM3 and PGM4 which both have unique DSPFs associated), the screen is "saved" and when you exit from the new screen the saved screen is restored.  My guess is that this "save" only happens the first time the screen is suspended.  After that it restores the first time save each time.