Rexx program working abnormally sometimes when executed through JCL

5 pts.
Tags:
Datasets
JCL
REXX
REXX Mainframe
REXX Procedure
I have a Rexx program to browse a very big dataset(say 75,000 lines) and then add 1 or 2 lines then save and end. This is working fine in online or batch execution provided dataset has only few records. However it works fine for all if running in ISPF panel itself, but through jcl execution for browsing big dataset the loop is going abnormally here and there and ends...not able to conclude what is going wrong? please share your ideas if you have any
ASKED: October 7, 2010  12:07 PM
UPDATED: October 8, 2010  2:10 PM

Answer Wiki

Thanks. We'll let you know when a new response is added.

in ISPF it works against large and small datasets

in batch against small dataset, it works.

when you run it in batch against a large dataset “the loop is going abnormally here and there and ends.”

Does “the loop” refer to your REXX code?
So the REXX code is NOT following the prescribed logic path? But only sometimes.

On the surface it would seem that this should not be happening. If it works, then it should work. If it fails, it should always fail.

Did the REXX run correctly before your changes?
If so, then I think we know what is wrong.

Ensure no error messages from either batch or interactive.
Make sure you have not suppressed error messages.

Make sure you are checking return codes. ALWAYS. for example:
“ISPEXEC LMOPEN DATAID(“dsid”) OPTION(OUTPUT)”
IF rc /= 0 THEN DO
zedsmsg = ‘LMOPEN FAILED WITH RC’ rc

Run the REXX with some of the traces turned on.

REXX is a programming language. And like any language, it can have logic errors in it. Normal debugging applies.

Is the batch job allocating to the proper libraries?
Sure you are running the same REXX program in both places?

Discuss This Question:  

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following