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
Answer Posted / guest
I hope SUBFLD1 is erroneously written as SUB-FLD1
Is This Answer Correct ? | 0 Yes | 0 No |
Post New Answer View All Answers
2 input fles: 2 flat files, with different number of records. both are having unique key for each record and already sorted in ascending order . match these files using unique key and in output only matching key value has to be written. please procide cobol logic
explain sorting techniques in cobol program?
How to read the 2nd last record of a VSAM file? (The file size is huge and we don't know the key)
How do get the result of your program directly on your pc?
How do we get current date from system with century in COBOL?
what is the use of outrecord?
How to find out the closest prime number of an input number? I believe it has something to do with SEARCH and COBOL Linear Array.
i need a small 3d program using inline and outline.
Explain about different table spaces.
What are the pertinent COBOL
How to change size of Initial number of records to *NOMAX for ALL PF files from perticular library, how can I do that
What is the compute verb? How is it used?
For rewrite, why is it mandatory that file needs to be opened?
What are the different data types in cobol?
How to get the last record in vsam file in cluster? And how can you get the kids file records into your cobol program?