ASSIGN PROGRAM



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

ASSIGN PROGRAM

Postby pranav283 » Tue Apr 17, 2018 12:00 pm

Hi,

Is there any possibility that the below CICS ASSIGN PROGRAM name could not assign the current program name to the variable WV-PGM:

EXEC CICS ASSIGN                      
          PROGRAM (WV-PGM)
          RESP    (WV-EIBRESP)        
END-EXEC                              
 


Lets say the current program name is - PGMOLCB1 and WV-PGM is defined as PIC X(08).
pranav283
 
Posts: 46
Joined: Sat Aug 30, 2014 3:52 pm
Has thanked: 2 times
Been thanked: 0 time

Re: ASSIGN PROGRAM

 

Re: ASSIGN PROGRAM

Postby Robert Sample » Tue Apr 17, 2018 5:18 pm

According to the manual, the ASSIGN PROGRAM will return the 8-character name of the currently executing program. So the answer to your question is no, there is no possibility that ASSIGN PROGRAM will not return the name of the currently executing program. HOWEVER, note that if a COBOL CALL is used to invoke a subprogram, CICS does not know about that CALL and hence will return the name of the currently executing main program, not the name of the subprogram since the subprogram executes as part of the main program.

These users thanked the author Robert Sample for the post:
pranav283 (Mon Apr 23, 2018 12:00 pm)
Robert Sample
Global moderator
 
Posts: 3624
Joined: Sat Dec 19, 2009 8:32 pm
Location: Dubuque, Iowa, USA
Has thanked: 1 time
Been thanked: 267 times

Re: ASSIGN PROGRAM

Postby pranav283 » Mon Apr 23, 2018 11:59 am

Thanks for the clarification Robert!

And sorry for the late reply..
pranav283
 
Posts: 46
Joined: Sat Aug 30, 2014 3:52 pm
Has thanked: 2 times
Been thanked: 0 time


Return to CICS

 


  • Related topics
    Replies
    Views
    Last post