Can anyone explain me CALL procedure in COBOL.Does it
carries similarities like call by reference in C.
Answer Posted / sravani
CALL statement is used to whenever if we want to call any subprograms in the main program.
The call can be a dynamic call or static call.
In static call the subprogram is compiled alone with the main program where as in dynamic call the calling program and called program will be compiled separately.
If there were any changes in the subprogram then main program also needs to be recompiled in case of static call its not required in dynamic call.
For static call NODYNAM is choosen and for dynamic call DYNAM is choosen. For static call the program name is passed directly for dynamic call the program name is declared in working storage section and it will be called using the working storage variable.
Various ways of calling the subprograms using call statement
CALL WS_PGM using by reference using identifier-1, identifier-2.
CALL WS-PGM using by content using identifier-1, identifier-2.
CALL WS-PGM using by value using identifier-1, identifier-2.
CALL WS-PGM.
| Is This Answer Correct ? | 3 Yes | 0 No |
Post New Answer View All Answers
System Testing for Mainframe Developers What is System Testing? integration testing ? what's the procedure ..
How to use the same COBOL program in Batch and CICS on lines? explain with an example
What is the compute verb? How is it used?
What are declaratives and what are their uses in cobol?
What is the difference between comp and comp-3?
What do you understand by psb and acb?
What is the Purpose of POINTER Phrase in STRING command in COBOL?
What are the rules of the move verb?
What is the difference between goback, stop run and exit program in cobol?
What is redefines clause in COBOL?
Program A (Normal COBBAT) calling a B Program (DB2COBOL, COBBATDB which is using a VSAM file. its a dynamic call. How we will handle VSAM file decleration in our from JCL from where we are running A PGM. And should we have PLAN for A pGM also. if possible can some one post a sample JCL. Thanks for help in advance.
example for sub strings ? and refernce modifications whit output pls
how do you reference the variable unblock file formats from cobol programs
How to traceback if I am getting SOC7 or SOC4 abend? List down the steps
explain sorting techniques in cobol program?