|
Greetings all... The topic is quite timely. I was just in aconversation
this morning with a fellow programmer who insists that lack of use of theimmediately
file name can cause "unintended results".....even if you check
after the read/chain/setll.copied,
Under normal practice I do not qualify the bifs for the simple reason of
cut-n-paste. Tests for valid reads ALWAYS occur immediately after a
read/chain/setll/etc. (Why continue processing if you don't have the
record.....beside the program has to do something because of the failure,
why not do it now?). Qualifying the bif means that when code is
not only does the read statement change, but the test using the bif hasto
change also.was
I've only had one issue with the bif and that was chaining to an update
file. The program had a one time failure because either the "%found"
not qualified, or the "and not %error" was not specified. The programseparated
tried to update a record that was never read apparently due to a record
lock. Both "fixes" were implemented so I don't have a definitive answer
as to which was the real problem. I tend to believe the real issue was
the lack of the "and not %error" portion of the test. I never could
reproduce the error any other way.
Has anyone had any real issues in not qualifying the bif with the file
name......other than cases where the I/O Opcode and the test were
by more than one statement number?list
--
This is the RPG programming on the AS400 / iSeries (RPG400-L) mailing
To post a message email: RPG400-L@xxxxxxxxxxxx
To subscribe, unsubscribe, or change list options,
visit: http://lists.midrange.com/mailman/listinfo/rpg400-l
or email: RPG400-L-request@xxxxxxxxxxxx
Before posting, please take a moment to review the archives
at http://archive.midrange.com/rpg400-l.
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2025 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.