× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



I follow an adise I read somewere: always use the file name in the %EOF, %FUOND, %EQUAL, etc. to avoid surprises from indicator set by other operation than the one intended. Specialy after pgm maintanance.

Joe Pluta wrote:

This is a new one to me, so I thought I'd share. Sometimes I do a full subfile load, and usually I condition the loop on EOF on the file being read. Not to go into a ton of detail, but this time I conditioned on generic %EOF and I was surprised to find my loop ending after filling one page and one record of my subfile.

Well, here's what happened: My subfile was defined with SFLPAG of 16 and SFLSIZ of 17 (the traditional method of defining an expanding subfile). Unbeknownst to me, writing record 17 to that subfile turns on the EOF setting, which is returned by the generic %EOF BIF!

So I changed my loop to end when RRN = 9999 and the problem went away. But it was interesting enough that I thought I'd share.

Joe



As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].

Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.