How to get RC from an online program in JCL?



Support for CICS/ESA, CICS/TS & Transaction Gateway, CICS Configuration Manager and CICS Performance Analyzer

How to get RC from an online program in JCL?

Postby aji1234 » Thu Apr 28, 2011 1:31 am

I am running a job which initiates some transaction and triggers an online program thereby. I get some error code in the program and I can find that code in the CICS log in that region. (does rollback and updates the record again with 00 status). But my intent is that the job needs to get the Return Code of that Online program. I think that is not possible or may be is there any other ways to resolve this?

like checking for SQL code in another step . and If it has 00 status then send RC as 99..??

Please suggest.
Thanks,
Ajit
aji1234
 
Posts: 3
Joined: Thu Apr 28, 2011 1:20 am
Has thanked: 0 time
Been thanked: 0 time

Re: How to get RC from an online program in JCL?

 

Re: How to get RC from an online program in JCL?

Postby Suny » Thu Apr 28, 2011 9:28 pm

Hi,

If you use CICS Abend calls for all you abend conditions, it transferres the control to Abend routine which produces the dump you see. It depend on how you handle your abend state. Instead of using CICS abend command you can return your program to whatever batch program has called it and pass on the return code of any function that produced this error. If you called this from a Batch Job, batch program can handle this return code and abend your program.

Disclaimer: I have never done or even tried such a thing.
Suny
 
Posts: 8
Joined: Thu Apr 21, 2011 3:57 pm
Has thanked: 0 time
Been thanked: 0 time

Re: How to get RC from an online program in JCL?

Postby aji1234 » Thu May 26, 2011 11:22 am

Hi Suny,

Thanks for your reply. But I could not implement that method.
Instead in the JCL
1->Batch program
2->Scheduler which initiates the transaction based on the input parameters also that online program writes a queue and file.
3->data read by a batch program from the file.
4->batch program - here the data which is checked for its status and depending on the status RC is sent and printed to spool.

Regs,
Ajit
aji1234
 
Posts: 3
Joined: Thu Apr 28, 2011 1:20 am
Has thanked: 0 time
Been thanked: 0 time


Return to CICS

 


  • Related topics
    Replies
    Views
    Last post