I want to declare a field with data type Double in my COBOL
program. how shall i do that ?
Answers were Sorted based on User's Feedback
Answer / tarunam
To Declare field with double data type u have to declare it
with comp-2
eg: PIC s9(8) usage is comp-2
| Is This Answer Correct ? | 8 Yes | 0 No |
Answer / prasad
With the above answer we can achive decimal numeric
declaration but we will not achive double format
declaration.
To Declare double data type in COBOL we have to decalre
field with COMP-3.
Examples:
WS-NUM PIC 9(4) COMP-3. for non decimal numbers
WS-NUM1 PIC 9(4) v 99 COMP-3. For decimal values.
| Is This Answer Correct ? | 3 Yes | 1 No |
Answer / i go crazy
For COMP-2 we will not give PIC clause. By default it takes 8 bytes.
| Is This Answer Correct ? | 2 Yes | 0 No |
wht r the advantages of 77 level number ?
what are the limitations of Inline Perform?
How many maximum number of procedures can we write in one COBOL program?
Hi Devolopers.. i need ur help.. i have 3 years of exp in Manual testing and SQL, next month onwards i shifted in to MAINFRAME TESTING... i have ZERO Knowledge abt mainframes.... PLS SUGGEST ME WHAT I LEARN in AMEERPET? mainframe testing or mainframe total devolopment subject... AS a devoloper u know every thing tester what to do PLSSSSSSSSS help me ITS VERY URGENT...
what is the use of comp2 ? where can we use it with example ?
how will u find out 3rd week's 2nd day using occurs ?
i need the code for this program in cobol. 2 + 1 = 3 4+3=7 6+5=11 8+7=15 10+9=19
What are the different rules of SORT operation?
what is meaning by design document? who can repared for this?
How many times the loop runs here 01 a pic 9(2) value 10. perform para1 a times stop run. para1: move 20 to a.
i have 10 names in an array and my name is one of them also array is not in sorted order i need to display my name using index how will i do this
Suppose, file A has 100 records and file B has 500 records. We want to write records common to both A and B into file C and records which are present only in either A or B into another file D. What should be the logic of Cobol program to achieve this?
7 Answers Bank Of America, Mind Tree,