Information Technology Reference
In-Depth Information
There are certain abends that can't be avoided but some should never occur. A
zero divide is one and it can be avoided by doing a check before the actual division takes
place. If the divisor is zero, don't perform the operation. As far as bad data goes, do as
much as possible to minimize these interruptions. Data comes from input or it can be
generated by the system. If the latter, that is, if some program generates the data, you
should always have good data. If not, make changes to the programs generating the data
so that it is always integral.
On the other hand, if the data is keyed into the system, you have less control but
you can always do preliminary checking and reject invalid data, especially fields that
should be numeric and aren't. Even if the data is coming from an outside source, you can
put in similar verifications before the actual processing. This will mean fewer if any
abends due to bad data. Not long ago I had just this situation where a file was originating
from outside and we had a program that did initial checking to make sure the fields were
what they were supposed to be. If they weren't, the next program that actually processed
the data just didn't run.
That last action may have been rather drastic but maybe it had to be done. Another
alternative might be to skip the record in error and go on to the next good record. This
approach will still prevent the possible abend and you'd probably care to put some kind
of message on an error report for the record in error. Someone would then see it and take
appropriate action.
Other problems, like I/O errors, could result from a tape drive that merely needed
cleaning. Space problems and file not found can be minimized by diligence in what
should be happening. Obviously you can't prevent all problems, but taking care of the
majority so that they are almost an impossibility of occurring will keep everyone happier.
A bit of thought and analysis ahead of time will make weekends and evenings almost
virtually trouble-free.
Reading dumps and determining what each system code means will be a part of
your learning process when you begin a new job. Fortunately there should be
documentation to aid you in these concerns and your fellow workers will be more than
happy to guide you in learning as much as you need to know. If your compatriots aren't
helpful, make a batch of brownies with Ex-Lax, remembering not to indulge. Each
company will have different problems as well as different tools to solve them and in a
matter of time you will be comfortable in these environments.
Let's get back to the method I suggested before for obtaining zip code data. We'll
use something similar to an array, called a table. For this new program,
accttable ,
we'll steal code from
acctsly
of chapter 13.
Search WWH ::




Custom Search