What is the difference between comp and comp-3 usage?
Explain other COBOL usage?s.

Answer Posted / elite group

Comp -- binary form
Comp-3 Packed Decimal

Usages are:
Display: Default it occupies the number of bytes is equal
to the size of the data-item
Comp -- Binary Number of bytes is equal to the size of the
data-item
Comp-1 -- 4-Bytes no pic clause is required
Comp-2 -- 8-byted no pic caluse is required, Double
precision
Comp-3 -- Packed Decimal Number of bytes is
(n+1)/2 -- if n is odd
(n/2)+1 -- if n is even
Comp-4 --- Same as Comp

Is This Answer Correct ?    57 Yes 14 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

Can we redefine the field of x(200) to less than 200?

836


I have a File that has duplicate records. I need only those records that occur more than thrice.?

8680


What is the difference between Global and External Variables?

676


State the various causes of s0c1, s0c5 and s0c7.

667


Which is the default, TEST BEFORE or TEST AFTER for a PERFORM statement?

837






What is the default value(s) for an initialize and what keyword allows for an override of the default?

703


I have a program with an Array of 5000 occurences which is being passed from 5 sub levels to the front end screen. Thess 5 programs using each 5*2 = 10 different arrays with size as 5000. This is causing the transaction to utilize more storage consupmtion. I am looking to reduce the storage consumption. As part of that initially i thought Dynamic array may solve my problem. After viewing the comments given i see its same as normal array. IS there any other way we can resolve this issue?

1238


What is a SSRANGE and NOSSRANGE?

838


What guidelines should be followed to write a structured cobol prgm?

677


For rewrite, why is it mandatory that file needs to be opened?

627


Which is not true about evaluate statement

1630


Write a program that uses move corresponding.

686


What is the Purpose of Pointer in the string?

651


if we display var1 then what will b displayed in below condition. 77 var1 pic s9(2) value -10. 77 var1 pic s9(2) value -11. " " " -12. " " " -13. -14 ... ... -19.

5708


What are different data types in cobol?

701