how many bytes does s9(7)COMP-3 field occupies?
Answers were Sorted based on User's Feedback
Answer / sekhar
s9(7)COMP-3
s occupius 1/2 bytes so 1/2+1/2(extra)=1 byte
1+7=8comp3
4 bytes
Is This Answer Correct ? | 9 Yes | 2 No |
Answer / vijayamala
s9(7)comp3
n=7 , (n+1)/2 = (7+1)/2 = 4.
4 bytes will be allocated for this numeric data item.
since comp3 is a packed decimal representation, each byte
can hold 2 data items. which means it 4 bytes can occupy 8
items. In which last item is left for sign digit. So
s9(4)comp3 will have 4bytes allocated & can hold 7 data
item and 1 sign digit in it.
Is This Answer Correct ? | 5 Yes | 1 No |
what is ASRA, AEY9?
Scenario: I have 3 Input Files.Read the first i/p file and depending on certain business logic, I want to read wither i/p file-2 or i/p file-3.Now, depending on certain business logic applied to the record read from either file-2 or file-3, I decide to write them to either output file-2 or output file-2. Question: How many job steps are necessary to implement a solution for the above.
How to execute a set of JCL statements from a COBOL program?
01 a pic 9(3) value is 123 01 b pic 9(6) move a to b wht will be the value ? and 01 a pic x(6) value is abc 01 b pic x(3) move a to b wht will be the value ?
How to define variable 9(20) in COBOL, because compiler does not allow us to declare variables with Pic 9(18). Can anyone please let me know the answer... I know one answer to this question which is to use Compiler option Arith (Extend) during Compilation. It extends the maximum limit to 9(32)..Just wanted to know if there is any other way to extend this?
What are the differences between OS VS COBOL and VS COBOL II?
What divisions, sections and paragraphs are mandatory for a COBOL program?
how do you reference the ksds vsam file formats from cobol programs
can you please let me know if there is any walkins for COBOL/PLI/DB2/IMS/JCL in pune other than IBM and ITC infotech
hi. This is Ram.i have one doubt.why can't we display comp-3 variables directly? let me answer quickly plez........
wirte a pgm in using files in which we hav 10 ,20,30 40...100 records in inputfile and i want them to be send to outputfile in reverse order. PLZ HELP ME OUT .........THIS IS A RECENT QUESTION IN IGATE..
How to find How Many Lines in Sysin DD * Parameter Thru Cobol Coding? If any one knows the Answer Please Reply .....Thanks From Shree