What do you understand by passing by reference and passing by content?



What do you understand by passing by reference and passing by content?..

Answer / robertd903

Passing by reference, is passing the ADDRESS of a variable--to a subprogram. The subprogram is able to change the value contained in the variable.

Passing by content is passing the DATA contained within a variable--to a subprogram. The subprogram can NOT change the value of the data in the (calling program's) variable.

Is This Answer Correct ?    0 Yes 0 No

Post New Answer

More COBOL Interview Questions

I need to compare 3 variables(dates) and do some processing based on the earliest date. There could be more then 1 date record in any of the 3 fields. What is the best way to code this?

0 Answers  


What is EIBCALEN? Why it is used?

9 Answers   ADP,


I am getting S00F abend when i try to compare two variable of different pic class,one variable is of 9(09) and another is S9(09) comp-3. First i moved the data from S9(09) comp-3 to 9(09), but no luck. So i tried to move the data from S9(09) comp-3 to X (09) and move to 9(09). I am getting same error message, Please help me to find solution for this ptoblem. ERROR MESSAGE - "The system or user abend S00F R=NULL was issued."

1 Answers  


What will happen if we generate GDG (+2) version without generating (+1) version?

2 Answers   IBM, T systems,


When is a scope terminator mandatory?

3 Answers  






what is subscript in cobol?give realtime example?

2 Answers   Wipro,


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,


What do you understand by passing by reference and passing by content?

1 Answers  


Which of the following paragraphs is compulsory in every COBOL program? (a) SPECIAL-NAMES (b) PROGRAM-ID (c) FILE-CONTROL (d) OBJECT-COMPUTER

4 Answers  


when COMP-3 is preferrable?

3 Answers   Patni,


What are the divisions in a cobol program?

1 Answers  


i want to learn mainframes. i completed MCA ,whats the future of mainframes

5 Answers  


Categories