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
What are the cobol coding sheets?
What is the usage of comp fields in cobol?
if we display var1 then what will b displayed in below condition. 77 var1 pic s9(2) value -10. 77 var1 pic s9(2) value -11. " " " -12. " " " -13. -14 ... ... -19.
What is static and dynamic call in cobol?
What is rmode(any) ?
Write the code to count the sum of n natural numbers.
i was faced one question- i have value -00001234.56 Suppress the zeroes and the output should be -1234.56 But Not - 1234.56 spaces should not be available after suppressing the zeroes. logic in jcl and cobol?
What are the rules of the move verb?
Name the divisions, which are available in a cobol program?
What is link edit in cobol?
What is the local-storage section?
What is the default value(s) for an initialize? What keyword will allow for an override of the default?
Explain how will you differentiate between an internal and an external sort, the pros and cons, internal sort syntax etc
What is amode(24), amode(31), rmode(24) and rmode(any) (applicable to only mvsesa enterprise server) ?
What is difference between static and dynamic call in cobol?