|
CPF4128 Escapelist
Message . . . . : Not able to allocate objects needed for file
I have a program that runs every weeknight. Once a month, it will
crash because the monthend process does ALCOBJ *EXCL on one of the
files my program reads.
If I were in CL, I would likely do an appropriate ALCOBJ and MONMSG,
then do "something" (probably sleep for 5 minutes then try again) if
the file is allocated (i.e. not run my program that uses the file!)
My driver program is RPG, though.
I'm thinking I probably need to use CALLP(E) or MONITOR, probably in
the driver program. It seems to me the program actually attempting
the file open is not the right place to check for the error. I see
CALLP(E) sets %Status, and 00202 says Called program or procedure
failed (and a couple other statuses same but with halt indicators
on). Can I specifically see that the error is the one I'm looking
for and not something else?
Am I on the right track or is there an ALCOBJ equivalent in RPG? Or
perhaps I need to use the trick of getting messages from the joblog,
but that seems messier.
Sean Porterfield
Sr. Systems and Network Engineer
Beacon Roofing Supply
919-739-8126
This email is confidential, intended only for the named recipient(s)
above and may contain information that is privileged. If you have
received this message in error or are not the named recipient(s),
please notify the sender immediately and delete this email message
from your computer as any and all unauthorized distribution or use
of this message is strictly prohibited. Thank you.
--
This is the RPG programming on the IBM i / System i (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-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.