is this below syntax correct?

CALL 'subprg' using A,B

Please help

Answers were Sorted based on User's Feedback



is this below syntax correct? CALL 'subprg' using A,B Please help..

Answer / lu

yes, ...look at this ex:

For calling sub-modules DYNAMICALLY - Code:
In Working Storage Section -

01 WS-PROGRAM PIC X(08).

MOVE 'SUBPROGA' TO WS-PROGRAM
CALL WS-PROGRAM USING ....(Your Parameters)

MOVE 'SUBPROGB' TO WS-PROGRAM
CALL WS-PROGRAM USING ....(Your Parameters)

MOVE 'SUBPROGC' TO WS-PROGRAM
CALL WS-PROGRAM USING ....(Your Parameters)


For Calling STATICALLY, check your compiler option. If it
is NODYNAM then use -
Code:
CALL 'SUBPROGA' USING ...(Your parameters)
CALL 'SUBPROGB' USING ...(Your parameters)
CALL 'SUBPROGC' USING ...(Your parameters)

Is This Answer Correct ?    9 Yes 1 No

is this below syntax correct? CALL 'subprg' using A,B Please help..

Answer / billyboyo

Yes, your syntax is correct.

This is using the "call literal" option of IBM Cobol. If
you do need the call to be dynamic, specify the DYNAM
option on the compile.

If you were to have used "call data-name" then the call is
perforce dynamic and unaffected by DYNAM/NODYNAM compile
option.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More COBOL Interview Questions

Hi All, how is sign is stored in S9(17) comp-3 variable. Answer with an Example will be of great help.

5 Answers   EDS,


. How do we cast a variable in COBOL

1 Answers   HSBC,


What is file status 39 ?

10 Answers   JPMorgan Chase,


i have a variable block which is used in my cobol program as input file having records of 4080 after compilation while runing the program im getiing file attribut mismatch and it is saying tht the record length of the file is 4084 can any one knw the answer how to reslove it ?

2 Answers  


What is SDSF?

3 Answers  






suppose a cobol programme A calling programme B,C and D. If C undergoes some change what if A,B,C,D need to be recompiled or only C nee to be recompliled.

2 Answers   IBM,


WORKING-STORAGE SECTION. 01 A PIC X(3) VALUE 'ABC' 01 B PIC 9(3). PROCEDURE DIVISION. MOVE A TO B. STOP RUN. OUTPUT IS: AB3 WHY AND HOW THIS IS HAPPENING.

4 Answers   Atos Origin,


What is rmode(any) ?

0 Answers  


What is the output generated by the following code? 01 GRP-I. 05 SUBFLD1 PIC XX VALUE "AB". 05 FILTER PIC X(6) VALUE SPACES. 01 GRP-2 REDEFINED GRP-1. 05 SUB-FLD2 PIC XX. 05 SUB-FLD3 PIC XX. 05 FILTER PIC X(4). IF SUB-FLD1 NOT = SPACES DISPLAY "SUBFLD1" MOVE "ABBCCD" TO GRP-1 IF SUB-FLD3 = SPACES DISPLAY "SPACES" ELSE DISPLAY "SUBFLD3" DISPLAY "END" ELSE DISPLAY "SPACES" DISPLAY "END". (a) SUBFLD1 SUBFLD3 END (b) SPACES END (c) SUBFLD1 END (d) SUBFLD1 SPACES

7 Answers   TCS,


when SE37 SB37 and sd37 occurs how to increase the volume , primary quantity and secondary quantity?

1 Answers   Hewitt,


how will u retreive value from a table.write it with syntex. 01 ws-table 05 ws-table1 occurs 10 times. 05 ws-table2 occurs 10 times. the above is 2 dimensional array..how will u retrieve 1st element of an array

3 Answers   ADP,


What will happen if we try to create GDG (+2) generaton instead of (+1) generation?

1 Answers  


Categories