What will happen if a variable is declared as below..
Explain with an example? Working storage section:-
01 WS-VARX PIC X(10) VALUE 'ABCDEFGHIJ'.
01 WS-VARN REDEFINES WS-VARX PIC 9(5) VALUE '12345'.
What will happen I am going to Display the WS-VARX and WS-
VARN?
Answer Posted / mallikarjun
WE CANNOT GIVE VALUE CLAUSE IN THE SECOND STATEMENT I.E.
WS-VARN REDEFINES WS-VARX PIC 9(5) VALUE '12345' . IF YOU
SPECIFY VALUE CLAUSE SYSTEM WILL SHOW AN ERROR, IF YOU
SPECIFY WITH OUT VALUE CLAUSE I.E.
WS-VARN REDEFINES WS-VARX PIC 9(5).
THEN IF YOU GIVE DISPLAY STATEMENT THEN ABCDEFGHIJ AND
ABCDE WILL BE DISPLAYED
Is This Answer Correct ? | 26 Yes | 3 No |
Post New Answer View All Answers
Differentiate cobol and cobol-ii. (Most of our programs are written in cobolii, so, it is good to know, how, this is different from cobol)?
how we sort two input files based on a common column and giving one o/p file please send me the coding logic?
What is the Purpose of Pointer in the string?
What are the access modes of START statement?
How do you reference the following file formats from cobol programs?
What are the pertinent COBOL commands?
What is an in line perform? When would you use it? Anything else you wish to say about it.
What is the default value(s) for an initialize and what keyword allows for an override of the default?
what is difference between cobol and cobol/400
What are the different open modes available in cobol?
What is a SSRANGE and NOSSRANGE?
input 1 input2 ouput1 output2 output 3 1 re 300 1 re 200 1 re 300 3 rc 500 1 re 200 2 rr 400 1 re 300 2 rr 400 1 rc 400 3 rc 500 1 rc 400 2 rr 700 2 rr 700 5 tt 900 5 tt 900 2 inputs r in flat file and output 1 is matched records,ouptput2 is unmatched of input1,output3 is unmatched of input2! how vl u get the output files using sequential order and to check with each and every records! let me know the procedure division ?
What is length is cobol?
In which area will you utilize 88 level items in cobol?
HOw can I get the negative sign while deduct high value from low value