View previous topic :: View next topic
|
Author |
Message |
sprikitik
New User
Joined: 29 Jan 2007 Posts: 61 Location: Makati City, Philippines
|
|
|
|
Hi,
I have a 2 programs PGM1 (transid=IN01) and PGM2 (no transID)
PGM2 i called by PGM1
if PGM2 issued:
EXEC CICS RETURN
TRANSID (EIBTRNID)
COMMAREA (COMM-AREA)
LENGTH (COMM-LENGTH)
END-EXEC
where will will the program return?
what i want to do is to return to PGM2. How can i do that?
Thanks |
|
Back to top |
|
|
Peter Zimmermann
New User
Joined: 04 Aug 2008 Posts: 1 Location: Heidelberg
|
|
|
|
sprikitik wrote: |
Hi,
I have a 2 programs PGM1 (transid=IN01) and PGM2 (no transID)
PGM2 i called by PGM1
if PGM2 issued:
EXEC CICS RETURN
TRANSID (EIBTRNID)
COMMAREA (COMM-AREA)
LENGTH (COMM-LENGTH)
END-EXEC
where will will the program return?
what i want to do is to return to PGM2. How can i do that?
Thanks |
Hi,
in PGM1 you can return to pgm2 with
EXEC CICS XCTL ....
PGM2 startet new with first statement.
Or your PGM2 to call PGM1 with
EXEC CICS LINK ....
The return-point in PGM2 ist the next statement after EXEC CICS LINK...
when PGM1 is finished.
I hope that is helpfull for your problem. |
|
Back to top |
|
|
Earl Haigh
Active User
Joined: 25 Jul 2006 Posts: 475
|
|
|
|
I have a 2 programs PGM1 (transid=IN01) and PGM2 (no transID)
PGM2 i called by PGM1
if PGM2 issued:
EXEC CICS RETURN
TRANSID (EIBTRNID)
COMMAREA (COMM-AREA)
LENGTH (COMM-LENGTH)
END-EXEC
where will will the program return?
what i want to do is to return to PGM2. How can i do that?
(1) PGM2 will return to the transid of PGM1
(2) You can not return to PGM2 with your current logic |
|
Back to top |
|
|
Suresh Ponnusamy
Active User
Joined: 22 Feb 2008 Posts: 107 Location: New York
|
|
|
|
Program A (has Tran ID) can call N number of programs PGM B, PGM C, PGM D etc (No Transaction). Everything will be considered as single Run Unit. So from any of the called program, if we specify EXEC CICS RETURN END-EXEC, CICS will return the control to the Main Program.
I do not think we can do XCTL from a Program which has Transaction to the Program which do not have transaction. XCTL transfer control from one program to another at the same logical level. You cannot return to the calling program.
Correct me If I am wrong. |
|
Back to top |
|
|
|