MVSFORUMS.com Forum Index MVSFORUMS.com
A Community of and for MVS Professionals
 
 FAQFAQ   SearchSearch   Quick Manuals   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

Inserting paragraph through REXX

 
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF
View previous topic :: View next topic  
Author Message
ayush
Beginner


Joined: 26 Feb 2004
Posts: 20
Topics: 14

PostPosted: Thu Jan 26, 2006 9:35 pm    Post subject: Inserting paragraph through REXX Reply with quote

Hi,
I have to insert a paragraph depending on the parms supplied in a cobol program.
I have to design a common error routine, which will be called in IDMS and CICS programs, if this routine fails in CICS program,it'll write the error message to the TCP and if it fails in IDMS program, it'll write the error message to OLP. This error routine has to be called by online programs only.

Is it possible to do so by REXX or any other method?
Please help.
Thanks.
Ayush
Back to top
View user's profile Send private message AIM Address Yahoo Messenger
Dibakar
Advanced


Joined: 02 Dec 2002
Posts: 700
Topics: 63
Location: USA

PostPosted: Thu Jan 26, 2006 11:21 pm    Post subject: Reply with quote

Why not make a copybook and use "COPY REPLACING".

Regards,
Diba.
Back to top
View user's profile Send private message Send e-mail
ayush
Beginner


Joined: 26 Feb 2004
Posts: 20
Topics: 14

PostPosted: Fri Jan 27, 2006 11:14 am    Post subject: Reply with quote

Hi Dibakar,

Thanks for the help. But I couldnt get what you mean.
Please let me know if my problem is not clear.
My code should work like:
If NOT-MQ-STATUS-OK
If IDMS
write error log to OLP
else
write error log to TCP
end-if
end-if.

When I include this in my IDMS program, the code errors because it won't recognize the CICS step to write logs into TCPI.
Similary when I compile it for CICS it won't recognize the IDMS step of error loggin (say SNAPS).
I want to dynamically generate this condition only inserting one of the either depending on what kind of program I am using.

Thanks.
Ayush


Thanks.
Ayush
Back to top
View user's profile Send private message AIM Address Yahoo Messenger
Dibakar
Advanced


Joined: 02 Dec 2002
Posts: 700
Topics: 63
Location: USA

PostPosted: Mon Jan 30, 2006 5:19 am    Post subject: Reply with quote

Ayush,

Ok, my earlier answer wouldn't have helped in this case so here is my suggestion.

Make two copybooks, COPYCICS and COPYIDMS, and include the appropriate one while coding.

COPYCICS -
Code:
If NOT-CICS-MQ-STATUS-OK
write error log to TCP
end-if.

COPYIDMS -
Code:
If NOT-IDMS-MQ-STATUS-OK 
write error log to OLP
end-if.

Let me know if this helps, looks like I am missing something.

Regrads,
Diba.
Back to top
View user's profile Send private message Send e-mail
Display posts from previous:   
Post new topic   Reply to topic   printer-friendly view    MVSFORUMS.com Forum Index -> TSO and ISPF All times are GMT - 5 Hours
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum


MVSFORUMS
Powered by phpBB © 2001, 2005 phpBB Group