A Cobol Call can be done from a batch or a CICS program and is used to pass and receive data back from another cobol program. CALL XPDF321 USING PDF321-LK. would be a dynamic call (resolved at execution time), CALL 'XPDF321' USING PDF321-LK would be a static call resolved when the program is compiled. A call from a CICS program would be outside of CICS since it does not involve the exec cics command.
A link is a CICS command and is used to pass data to and receive data from a CICS program. data is passed in the CICS commarea.
Above answer was rated as good by the following members: memays
RE: What is te difference between Call and Link in cob...
A Cobol Call can be done from a batch or a CICS program and is used to pass and receive data back from another cobol program. CALL XPDF321 USING PDF321-LK. would be a dynamic call (resolved at execution time) CALL 'XPDF321' USING PDF321-LK would be a static call resolved when the program is compiled. A call from a CICS program would be outside of CICS since it does not involve the exec cics command.
A link is a CICS command and is used to pass data to and receive data from a CICS program. data is passed in the CICS commarea.
RE: What is the difference between Call and Link in co...
In the cal statement the called program is included in the load module so if we changed the called program we have to compile the load module again. but in the link we need not to recompile the load module after changing the linked program.
RE: What is the difference between Call and Link in cobol?
Be aware that CALL does not mean the called module is part of the load module. That is only true if it is a Static call. Dynamic calls do not include the called routine in the load module.
This question must be related to CICS since COBOL does not have a LINK statement. There are distinctions as listed below:
Static CALL: Called module is part of the load module. CICS knows nothing about it and doesn't get involved with the communication between the modules.
Dynamic CALL: Called module is not part of the load module. CICS needs a PPT entry for both the called and calling program. Under the covers CICS treats it like a LINK request. Arguments are passed as with a static call.
LINK: CICS command-level request to pass control to another module with a return back to the caller. Arguments are passed in a COMMAREA.