Can anyone explain me CALL procedure in COBOL.Does it
carries similarities like call by reference in C.



Can anyone explain me CALL procedure in COBOL.Does it carries similarities like call by reference ..

Answer / 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

More COBOL Interview Questions

in how many mode we can open a file ?

4 Answers  


What are INPUT PROCEDURE and OUTPUT PROCEDURE?

0 Answers  


In a COBOL II PERFORM statement, when is the conditional tested, before or after the perform execution?

3 Answers  


Where the Plan is located in CICS-DB2

2 Answers   IBM,


How do you come out of an EVALUATE statement?

3 Answers  






What are the different rules of SORT operation?

0 Answers  


can u plz expain me how to declare dynamic array? what is the meaning of depending on clause in dynamic array?

3 Answers   IBM, Satyam,


how do you reference the variable block file formats from cobol programs

0 Answers  


COBOL program to read the string ' BOMBAY' in reverse order as 'YABMOB'

8 Answers   Barclays, IBM,


What are different file OPEN modes available in COBOL?

4 Answers   Sun Life,


what is jcl approach for programming?

4 Answers   IBM,


how would you resolve sb37 and SE37?

2 Answers   Hewitt,


Categories