is it possible to declare index in cobol program?
if it is not why its tell me pls

Answers were Sorted based on User's Feedback



is it possible to declare index in cobol program? if it is not why its tell me pls..

Answer / amjith pillai

No need to 'Declare' Index in working Storage section.since
Index is internally represented by 'Index Register' which
is Full-Word binary.

Yes, you can directly mention Index in Occurs clause and
can increment and re-positioning the index variable

Is This Answer Correct ?    9 Yes 0 No

is it possible to declare index in cobol program? if it is not why its tell me pls..

Answer / reddy

YES ITS POSSIBLE.
IN ARRAYS WE CAN USE INDEX.

Is This Answer Correct ?    1 Yes 2 No

is it possible to declare index in cobol program? if it is not why its tell me pls..

Answer / kiran

yes it is possible

ex PERFORM TEST AFTER VARYING WS-INDEX FROM
1 BY 1 UNTIL WS-INDEX = 10
DISPLAY "WS-INDEX is now equal to " WS-INDEX
END-PERFORM

Is This Answer Correct ?    0 Yes 6 No

Post New Answer

More COBOL Interview Questions

How to convert bunch of words in a line to relvant ASCII values?

2 Answers  


i have two file, each file having : file1 is having 2 fields field1 field2 file2 is having 3 fields field1 field2 field3 my req is to make it one file like: field1 field2 field1 field2 field3 if anyone know please send me syntax, i tried this with DFSORT but could not succeed.

9 Answers   Syntel,


I have two files , file1 is input file it contains 10,20,30,....,records but i want to display the records in file 2 as reverse order .how can we do by using jcl& cobol(dont use array) please any one can tell me the answer

3 Answers   GreenTree, IBM,


How do you code Cobol to access a parameter that has been defined in JCL?

3 Answers  


What is normalisation?

2 Answers   IBM,


What is an in-line perform ?

4 Answers   Accenture,


1)what is use of linkage section? 2)what is difference between comp and comp-3

1 Answers   Cap Gemini,


How do we get current date from system with century in COBOL?

0 Answers   Winsol Solutions,


In COBOL, what is the different between index and subscript?

0 Answers   TryTechnicals Pvt Ltd,


Why is it necessary that file needs to be opened in I-O mode for REWRITE?

0 Answers  


COMPUTE X = A * B - C * D and COMPUTE X = (A * B) - (C * D) (a) Are not the same (b) Are same (c) Syntactically wrong (d) Will yield a run time error

1 Answers   TCS,


input= ,,,, mainframe training ,,, hyderabad .... location.... output1=$ mainframe training in hyderabad location$ output2=**** mainframe training in hyderabad location ****. In this pgn when we give input considering the spaces the output is displayed in this format.Like in the place of ,,,, $ should be displayed likewise.So please helpmeout.

0 Answers  


Categories