|
Emptying the MailbagBy Steve Hammond Dear JJ: You have come to
the right place for that information. MPEX offers some great JCWs to
test. So coming in, we know that
SUCCESS should be 33 and FAIL should be 0. If a database is open,
FAIL will be greater than 0. If a copy fails because of space, etc,
then SUCCESS will not be equal to 33. Nice little use of the
MPEXNUMSUCCEEDED and MPEXNUMFAILED variables, eh? Well, yes and no.
The tests are real slick except when you add a dataset to one of the
databases and forget to change the job stream. This usually results
in a late night phone call, which we all hate! Dear MPEX Answer Man: As
one of the last steps in a project I am working on, I had to
recompile all the programs, which was tedious. Then I discovered that
I had forgotten to PREP each of them with MR capabilities. Now I have
to go back and do this all over again. Can you help? Dear Mix: You too
have come to the right place! First of all, when you get time, look
at the section of the MPEX manual titled Using MPEX to Compile
Programs. That will tell you how to use MPEX to make the
compile process much faster. But since youre at this point,
Ill show you how to fix things from here. ALTFILE may be the
most powerful MPEX command, since it lets you alter any number
of file attributes. Here, assuming all the programs are in the group
OBJECT.PROD, you just %ALTFILE @.OBJECT.PROD(ISPROG);CAP=+MR Viola! Your programs (only
programs were done because of the attribute ISPROG) now have had MR
capability added. An even more interesting trick is %ALTFILE
@.OBJECT.PROD(ISPROG);CAP=+MR,-PM. That one added MR and remove PM
capabilities in the same fell swoop. Dear MPEX Answer Man:
Every fiscal year I have to store off an account, clear out all the
files and then rebuild them all over again. This is a mind-numbing
process and I always miss creating a file or I build a file wrong and
I have to come back and clean up my errors. I could write a script to
do it all, but I was hoping MPEX could help me. Dear OK: There is nothing I find more rewarding to write (aside from this column) than a nice script that performs multiple functions with intermediate tests to ensure everything is progressing properly. But forget all that. MPEX has a fairly new command called ERASE. This will erase the contents of all the target files but still leave the file structure (record size, ASCII vs. Binary, blocking factor, etc.) intact. Its like the purge without the final step of deleting the file! You will still need something to take care of any databases, such as Adager or DBGeneral, but your MPE files are now empty. Dear MPEX Answer Man: I
have just started dating a programmer. He seems like a nice enough
guy, but he appears to have no sense of humor. Is there something
wrong with him? When he does laugh, it seems to be at all the wrong
places. Is it me? Dear Confused: You dont say what kind of programmer he is. If he does all this Web or Java or Python or whatever endangered species they have named a programming language after this week, then give up now. Hes a lost cause. But if hes a COBOL or FORTRAN or machine language programmer, then hes a virile (I almost said viral), intelligent, thoughtful individual. An example of good programmer humor Why do programmers confuse Halloween with Christmas? Because OCT31 = DEC25! [Insert mocking hysterical laughter at an old joke] A better example go
into MPEX and execute the command %CALENDAR @;PICTURE Copyright The 3000 NewsWire. All rights reserved. |