View previous topic :: View next topic |
Author |
Message |
Jayakrishnan Beginner
Joined: 13 Sep 2005 Posts: 5 Topics: 3
|
Posted: Mon Nov 13, 2006 3:10 am Post subject: Replacing EXEC CICS START TRANS command with EXEC CICS LINK |
|
|
Hi Friends,
I need your sincere help in solving one of my project requirements. I shall explain you the scenario below :-
I have a C language program that resides in a CICS region. This C program internally invokes a transaction using EXEC CICS START TRANS command that executes a COBOL program within the same CICS region. A new project requirement has been initiated to replace this transaction call in the C program with an EXEC CICS LINK command. Can you all please guide me with the changes that I need to make on both the C program as well as on the COBOL program inorder to accept the project requirement.
Currently, the C program passes a pointer to a structure when it is invoking the COBOL program using the transaction. The COBOL accepts the incoming pointer using the EXEC CICS RETRIEVE command.
I think I may have to use a common area for passing data to the COBOL program as well as for receiving data from the COBOL program. ut I am not sure regarding the actual changes that i need to make on the calling program as well as on the called program side.
Thanks in advance. |
|
Back to top |
|
|
ravikumar_sri2001 Beginner
Joined: 06 Dec 2002 Posts: 117 Topics: 44 Location: Chennai,India
|
Posted: Sun Nov 19, 2006 11:41 pm Post subject: |
|
|
You can pass the pointer thru commarea from the calling program
EXEC CICS LINK(SUBPROGRAM) COMMAREA(WS-POINTER)
END-EXEC
In the called program, define a pointer under DFHCOMMAREA. Define the structure in linkage section. Using SET ADDRESS statement establish the addressability for the passed data.
01 DFHCOMMARA.
05 LS-POINTER POINTER.
01 PASSED-DATA PIC X(??).
SET ADDRESS OF PASSED-DATA TO LS-POINTER
Hope this helps you.
Thanks,
Ravikumar. |
|
Back to top |
|
|
Jayakrishnan Beginner
Joined: 13 Sep 2005 Posts: 5 Topics: 3
|
Posted: Tue Nov 21, 2006 1:05 pm Post subject: Thanks Ravi |
|
|
Dear Ravi,
Thanks for your help. Let me just try this out . Will let you know the progress.
Thanks much.
Regards,
Jayakrishnan |
|
Back to top |
|
|
|
|