can we display comp-3 variables. if we want to display what
we have to do . give me one example
Answer Posted / vivekananda
We can't display COMP-3 directly so we have to move the value into another variable, check this given example.
01 A1 PIC S9(4) COMP-3 VALUE 1234.
01 A1-NUM PIC S9(4) VALUE ZEROES.
01 B1 PIC X(4).
MOVE A1 TO A1-NUM.
MOVE A1-NUM TO B1.
DISPLAY B1.
Is This Answer Correct ? | 24 Yes | 6 No |
Post New Answer View All Answers
How many bytes S(8) comp field occupy and its maximum value?
How to get the last record in vsam file in cluster? And how can you get the ksds file records into your cobol program?
Difference between cobol and cobol-ii?
For rewrite, why is it mandatory that file needs to be opened?
how do you define single dimensional array and multidimensional array in your cobol?
How to know whether the module is dynamical or statistical?
What is perform what is varying?
what is amode(24), amode(31), rmode(24) and rmode(any)?
What are the different rules for performing sort operation?
What is the utilization of copybook in cobol?
i want to learn mainframe..any websites and material to learn from basic..? my mail id : rajeswaribe2010@gmail.com
System Testing for Mainframe Developers What is System Testing? integration testing ? what's the procedure ..
Why did you choose to work with ibm mainframe cobol programming?
What is redefines clause in COBOL?
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)?