I hav vari declaration like.....
77 a pic s9(9).99.
77 b pic s9(9).99 comp.
77 c pic s9(9).99 comp-3.
if i use MOVE 123456789.99 to a,b,c what happen every one
working fine ?



I hav vari declaration like..... 77 a pic s9(9).99. 77 b pic s9(9).99 comp. 77 c pic s9(9).99 com..

Answer / sri

comp does not work fine becoz it does not support decimal format

Is This Answer Correct ?    10 Yes 0 No

Post New Answer

More COBOL Interview Questions

HOw can I get the negative sign while deduct high value from low value

0 Answers  


What will happen if a variable is declared as below.. Explain with an example? Working storage section:- 01 WS-VARX PIC X(9) VALUE SPACES. 01 WS-VARN REDEFINES WS-VARX PIC 9(9).

8 Answers  


a pic s9(4) comp b pic s9(4) comp-3 c ???????????????? d ???????????????? move a to c add a+B giving d. what is ur declaration for c,d?

4 Answers  


How to Write the RESTART Logic Using COBOL?

4 Answers   GalaxE, L&T, Syntel, TCS,


period is missing in the cobol program which error we getting

5 Answers   TCS, Tesco,






what is the difference between start and startbr?

2 Answers  


can anybody post me about file-aid and changemen tools pls and give me reference if any mainframe guys are there

0 Answers  


Can we use goto statement in inline_perform ?

5 Answers   IBM,


what is soc7 abend?how u can trace it?

4 Answers   Accenture,


consider the following piece of code 01 GROUP-ITEM 05 AMOUNT-1 PIC 99V9 USAGE COMP VALUE 50 05 AMOUNT-2 PIC 9(4)V99 USAGE COMP MOVE ZERO TO GROUP-ITEM ADD 50 TO AMOUNT-1 what will be the content of AMOUNT-1? a.50 b.100 c.0 d.unpredictable

10 Answers   TCS,


Did anybody attend the walkin of TCS on 31st July in Gurgaon for any technology,If u have completed 3 round i.e till the HR round,have u received the Offer letter yet? Please let me know.Thanks.

1 Answers  


WORKING-STORAGE SECTION. 01 VAR1 COMP-2 VALUE 0. PROCEDURE DIVISION. MOVE 10.2115 TO VAR1. DISPLAY 'VAR1 =' VAR1. GOBACK. 10.2115 is stored as .10211499999999996E 02 in OS VS Cobol 10.2115 is stored as .10211500000000000E 02 in ecobol. Any reason why?

3 Answers   TCS,


Categories